Portal Engine Questions on portal engine and web parts.
Version 4.x > Portal Engine > TreeHelper.SelectNodes returning empty results when launched in a thread. View modes: 
User avatar
Member
Member
Monstesr - 9/24/2009 3:26:30 PM
   
TreeHelper.SelectNodes returning empty results when launched in a thread.
Hi,

I am trying to do some lazy loading of treenode objects, but when i call TreeHelper.SelectNodes from within a spawned thread, it returns 0 results, if i call it with the exact same paramters inline, it returns the correct results.

Does the TreeHelper.SelectNodes method require the current http context? If so, is there any way i can pass the context to the object? I have a reference to it within my thread..


User avatar
Kentico Support
Kentico Support
kentico_jurajo - 9/29/2009 3:30:29 AM
   
RE:TreeHelper.SelectNodes returning empty results when launched in a thread.
Hi,

Could you please try to use the SelectNodes method from CMS.TreeEngine.TreeProvider, since in TreeHelper it requires some data from current CMSContext.

I hope it will help.

Best Regards,
Juraj Ondrus