|
Rank: Advanced Member Groups: Member
Joined: 12/5/2007 Posts: 57
|
Hi,
I think I may have gotten my version and license file out of sync and as such I cannot get rid of the nag message. Do I need to locate and re-install an older version or am I entitled to the latest and if so how do I get a key for it?
Maybe this is related to the above or perhaps I am attempting to accomplish something incorrectly. What I need to do using the Tree Control is change the text displayed on 10 tree nodes at run time ideally when the page first loads. I have tried a few different things but they don't seem to work. I have also tried to set the PopulateOnDemand as well as the raises server event proprtres to true for the appropriate parent nodes in order to be able to put code in the event handlers to do this butr the events don't fire!
Any idea of what I am doing wrong here? Your help is greatly appreciated.
Regards
Gary
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,194
|
Hi, For the license issue, please see this post: http://www.essentialobjects.com/forum/postst119_License-troubleshooting.aspxYou do need to run a version that you have a license with; A mismatch will not work. To get the correct license file, you can go to "My Orders" page, then choose "View License", on the next page you should see options to download license key/file for EO.Web Controls 2008 or EO.Web Controls 2007.2. To change text for a TreeNode, use something like this:
Code: C#
TreeView1.Nodes[0].Text = "something";
It has nothing to do with license or anything else. In order to fire server event, you will need to set RaisesServerEvent to true. Thanks
|
|
Rank: Advanced Member Groups: Member
Joined: 12/5/2007 Posts: 57
|
Hi,
Thanks for the prompt response. I have now got the dll version and license back in sync and thus am no longer plagued by the nag message so that is one issue resolved. As for your suggestion on setting the text property I am still getting the same problem as before. Presently I am populating the entire contents of the treeview control using the designer. There are approximately 200 nodes in total. In the page load handler I have tried the following code:
Dim tmpNode As EO.Web.TreeNode tmpNode = tvContacts.Nodes(39) tmpNode.Text = Trim(Str(Year(Today) - 1))
Unfortunately this generates a runtime error telling me that the index is out of range! How can that be as I have manually entered all of the nodes and I know they are there? Invetigating a little further I set a break point in the code and oddly enough when I look at the count property of the nodes collection it only shows 1, go figure!
So I figure OK, maybe it has not yet fully populated and try putting the same code in the treeview's load event handler and guess what? Same problem!
So at what point I can I use you suggestion to access and change the text property of the nodes that need to be changed? Is there some property setting that I am missing that is causing the control to not fully load? The only reason I was asking about firing ta server event was to find a work around for this problem.
So, what's next?
Regards
Gary
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,194
|
Hi Gary,
We are not aware of any issue on Nodes collection or Count property. There has never been any problem on this. What you want to check maybe that tvContacts.Nodes only contains the top level nodes. The child nodes are not in tvContacts.Nodes. They will be in the parent node's ChildNodes property. So even if you have 200 nodes in total, but if you only have one root node, tvContacts.Nodes.Count will be 1.
Thanks
|
|
Rank: Advanced Member Groups: Member
Joined: 12/5/2007 Posts: 57
|
Hi,
Thanks for the prompt response again. I think you have identified the problem. I will try iterating the child nodes to see if that works and will then give you an update.
Regards
Gary
|
|
Rank: Advanced Member Groups: Member
Joined: 12/5/2007 Posts: 57
|
Thanks, that was the issue. All is now OK.
|
|