Infralution Support Forum Index Infralution Support
Support groups for Infralution products
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Failed to load resources from resource file

 
Post new topic   Reply to topic    Infralution Support Forum Index -> Virtual Tree Support
View previous topic :: View next topic  
Author Message
Andrew Rowley



Joined: 24 Dec 2005
Posts: 63

PostPosted: Wed Feb 14, 2007 7:09 am    Post subject: Failed to load resources from resource file Reply with quote

I have another problem which may or may not be related to my previous problem.

I have set up the virtual tree and can see the data. I can expand and collapse rows OK using the mouse.

I have some rows that when they are expanded, I also want to expand the children. I set up an event for the RowExpand, and in it I check the type and do:
e->Row->ExpandChildren(false);

I get the error:
Setup Error
Failed to load resources from resource file
Please check your Setup

Can you suggest what might cause this problem?

Thanks

Andrew Rowley
Back to top
View user's profile Send private message
Infralution



Joined: 28 Feb 2005
Posts: 5027

PostPosted: Wed Feb 14, 2007 9:16 pm    Post subject: Reply with quote

This does not look like an error that would be originating from Virtual Tree. Because calling ExpandRow will ultimately call back into your application code to retrieve data for the expanded rows the error may be originating in your code.

Have you got some more information (like a stack trace and the exception name)? Are you catching this as an exception in the debugger or running the application standalone?
_________________
Infralution Support
Back to top
View user's profile Send private message Visit poster's website
Andrew Rowley



Joined: 24 Dec 2005
Posts: 63

PostPosted: Thu Feb 15, 2007 11:07 pm    Post subject: Reply with quote

It turns out that this is a stack overflow exception. If I run it under the debugger, I see the exception. For some reason I don't get it when running it normally.

It seems that calling ExpandChildren from the RowExpand event is not a good idea. I think that when I call ExpandChildren, the RowExpand event fires again for the current row. Is there any way to get around this?

I have been through my tree and expanded every child row manually, so I know that I haven't got an endless tree or anything like that.
Back to top
View user's profile Send private message
Infralution



Joined: 28 Feb 2005
Posts: 5027

PostPosted: Fri Feb 16, 2007 12:01 am    Post subject: Reply with quote

What exactly are you trying to achieve? If you want the children of a node to expand when it is displayed you may want to investigate using the ChildPolicy.AutoExpand option - which you can set in the RowBindings or by handling the GetChildPolicy event
_________________
Infralution Support
Back to top
View user's profile Send private message Visit poster's website
Andrew Rowley



Joined: 24 Dec 2005
Posts: 63

PostPosted: Fri Feb 16, 2007 12:22 am    Post subject: Reply with quote

Thanks, that option does indeed do what I was trying to do. I just hadn't found it.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Infralution Support Forum Index -> Virtual Tree Support All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group