The Syncfusion native Blazor components library offers 70+ UI and Data Viz web controls that are responsive and lightweight for building modern web apps.
.NET PDF framework is a high-performance and comprehensive library used to create, read, merge, split, secure, edit, view, and review PDF files in C#/VB.NET.
Hi, I'm trying to use the HierarchicalDataTemplate with command binding and I can't figure out how to bind the command for the items created by the template.
I set the Command on the parent MenuItemAdv, but it only gets called when the parent gets clicked - not when any of its children gets click. That makes sense, but I don't see any other place to bind the command for the templated child items, though.
Where can I bind the command that the children in the hierarchical data call?
Which gave me the binding for the command, but then I get an unhandled exception on the click:
Webpage error details
User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.0; Trident/4.0; SLCC1; .NET CLR 2.0.50727; Media Center PC 5.0; .NET CLR 3.5.21022; .NET CLR 3.5.30729; FDM; .NET CLR 3.0.30729; .NET4.0C; .NET4.0E; MS-RTC LM 8; eMusic DLM/4; Zune 4.0) Timestamp: Wed, 16 Feb 2011 00:11:14 UTC
Message: Unhandled Error in Silverlight Application Code: 4004 Category: ManagedRuntimeError Message: System.NullReferenceException: Object reference not set to an instance of an object. at Syncfusion.Windows.Shared.MenuItemAdv.OnMouseLeftButtonDown(MouseButtonEventArgs e) at System.Windows.Controls.Control.OnMouseLeftButtonDown(Control ctrl, EventArgs e) at MS.Internal.JoltHelper.FireEvent(IntPtr unmanagedObj, IntPtr unmanagedObjArgs, Int32 argsTypeIndex, Int32 actualArgsTypeIndex, String eventName)
Can someone take a look at this please? It will soon be a blocking issue for us. Thanks!
SKSakthi Kumar A Syncfusion Team February 23, 2011 10:03 AM UTC
Hi Keith,
We are able to reproduce the MenuItemAdv command binding issue and we have logged a defect report internally. We have also created a new incident #77537 in our Direct-Trac system, so that we would be able to share the patch details with you. Please refer to the Direct – Trac incident for any further inquiries.