Jun 21, 2010, 11:09 PM
How can I call a DirectEvent o a GridPanel column with a command?
Hi guys, I have a GridPanel that has a column with 2 ImageCommands, I would like to show a window upon clicking on those icons, and I need to pass the clicked row unique id to the window in order to load the data,, I saw a demo with a Listener but can you help me reading the id from the DirectCommand or Can I call the window and pass the clicked row ID value using a Listener as well? It would be nice to learn both approaches.
Thank you
Grid Column
Thank you
Grid Column
<ext:Column DataIndex="dep_id" Width="55" Header="Actions" Align="Center" Sortable="false">
<Commands>
<ext:ImageCommand CommandName="Edit" Icon="Pencil" ToolTip-Text="Edit"></ext:ImageCommand>
<ext:ImageCommand CommandName="Print" Icon="Printer" ToolTip-Text="Print"></ext:ImageCommand>
</Commands>
</ext:Column>
Grid Event<DirectEvents>
<Command OnEvent="gridDataEdit_Click"></Command>
</DirectEvents>
<LoadMask ShowMask="true" />
Code Behindprotected void gridDataEdit_Click(object sender, DirectEventArgs e)
{
X.MessageBox.Alert("Alert", "You clicked me and your ID is???").Show();
}