While looking through the 10.3 documentation for the WebDataMenu, I noticed a new function called addItem, which is listed here:
http://help.infragistics.com/NetAdvantage/ASPNET/Current/CLR4.0/?page=WebDataMenu~Infragistics.Web.UI.WebDataMenu~addItem.html
This feature wasn't documented in any of the release notes, and I can't find any sample code, so I am trying to figure out how to use it using the debugger.
Here is what I have observed so far:
Can someone at Infragistics please provide some sliver of sample code that I can use to accomplish the following on the client:
Pretty please with cherries and a Star Wars action figure on top?
Also, the presence of the AJAX call indicates that maybe there is a way to do AJAX load-on-demand of submenu items. That is actually preferable to what I was going to do using a WebService. If you have any documentation on that, I'd be in your debt as well!
Hi Rob,
the actual adding and rendering happens on the server, that is why the AJAX call is needed. On the other side implementing pure client side add/remove methods with batching like in WebDataTree control is another story which stays in our backlog for the WebDataMenu. If you really need this you should talk to product management Murtaza Abdeali to adjust the priority on this feature.
Thanks,
Lubomir
ygalanter, thank you very much for the link... However, my menu structure isn't that predictable.
For the Infragistics team, here is some additional context...
I am trying to do this entirely client-side. The menu has not postback events. As such, I have ViewState turned off on the control in order to minimize the payload. I haven't had a chance to install the SR yet, but I have a feeling that having ViewState disabled is going to cause the ajax calls to fail.
If I have to enable ViewState, the additional payload will probably wipe out any savings I would get from not loading the menu items in the first place.
The more I look at this, the more I come to the conclusion that all of the overhead that comes with keeping the server in sync (ViewState, individual Ajax calls, and finding a way to detect when the Ajax call is completed) are going to wipe out any benefit that might be achieved.
One question/idea that might be rolled into the feature request... If ViewState is disabled, and there are not server-side postback events, is there really a technical need for the Ajax calls at all?
For pure client-side approach you can try this:
http://codecorner.galanter.net/2011/02/24/infragistics-webdatamenu-csom-additemremoveitem-workaround/
Thank you very much!
Hello Rob,
I created a new support ticket on your behalf
CAS-61230-QT10LM
I will submit a new feature request regarding this as Lubomir has advised.