iSeller Commerce
iSeller POS Retail
iSeller POS F&B
iSeller POS Express
Crosslight
WebUI
ClientUI
What's New
Download Trial
Web Solution
Mobile Solution
Enterprise Solution
Custom Development
Blog
Community
Latest Development Blogs
ForumPostTopic
Browse By Tag
Hi,
I need a sample for a simple tree-view using WebGrid version 6.0.7200.218.
It should use the event InitializeSelfReferenceDataSource to load the next node level data. And InitializeDataSource should load the root node data. And the columns are created in the code, not hardcoded in aspx page.
I think I have everything correct (too big to post here), but I just don't get the "plus" image to expand a node. How does WebGrid know if it needs to draw this plus image? What might be missing?
In any case such a sample would be great. I found the samples that use EnableLoadOnDemand (not supported in mentioned version) and the found samples mostly use data connectors in the aspx file, instead of creating the data in InitializeDataSource.
Thanks
If found my problem. I have this code:
<RootTable DataKeyField="Block_Id"> <Columns> <WebGridColumn Name="Description" DataMember="Detail_Name" /> <WebGridColumn Name="BlockId" DataMember="Block_Id" /> <WebGridColumn Name="ParentBlockId" DataMember="Parent_Block_Id" /> </Columns> <SelfReferencingSettings ChildDataMember="Parent_Block_Id" Enabled="True" ParentDataMember="Block_Id" ExpandColumnMember="Description" LoadOnDemand="True" /> </RootTable>
The two attributes ChildDataMember and ParentDataMember both point to a DataMember value of WebGridColumns. But ExpandColumnMember ("Description" above) is not the DataMember of a WebGridColumn, but the Name of a WebGridColumn. So for the example above I have to use ExpandColumnMember="Description" instead of ExpandColumnMember="Detail_Name". The code above shows the corrected version.
Where I copied it from, both Name and DataMember were the same, so it worked there.
Unfortunately WebGrid doesn't give any error message if ExpandColumnMember is wrong or cannot be not found; it simply won't show the "plus" to expand the node.
It also doesn't work, if the columns BlockId and ParentBlockId are hidden (Visible="false") and they do not have a Caption. I don't know why hidden columns must have Caption, but if you miss this attribute, the little plus-image for expanding the node also doesn't appear. That's probably another bug. As a workaround, just set Caption="".
Hello, Eric. I hope this finds you well - and still checking these boards.
I am attempting to use an Oracle connection to load self-referencing data and cannot seem to get it just right. Where exactly did you find an examplue using - InitializeSelfReferenceDataSource - I am unable to locate a working example in the forums.
Thank you.
To Frank P:
Please allow me to assist you with the sample file of WebGrid which uses InitializeSelfReferenceDataSource. The sample file name is SelfHierarchyLoadOnDemand.aspx. It is available in WebGrid Tutorials project (point your mouse to start > All Programs > Intersoft WebUI Studio 2011 R2 SP1 > WebUI Studio for ASP.NET > WebGrid 7 > C#/VB Tutorials). After the project opened, expand the V3.5 node in the Solution Explorer and you should be able to find SelfHierarchyLoadOnDemand.aspx tutorial file in here.
Should you need further assistance or run into any problems regarding this feature, feel free to post it in here. We would be happy to assist you again.
or
Choose this if you're already a member of Intersoft Community Forum. You can link your OpenID account to your existing Intersoft Social ID.
Choose this if you don't have an Intersoft account yet. Your authenticated OpenID will be automatically linked to your new Intersoft account.
Enter your Wordpress Blogname