This is a migrated thread and some comments may be shown as answers.

ButtonType="ImageButton" and var rowNo = args.get_commandArgument() ;

1 Answer 58 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Krzysztof
Top achievements
Rank 1
Krzysztof asked on 23 Nov 2008, 08:42 PM
Hi

When I set in grid :

<telerik:GridButtonColumn UniqueName="DeleteColumn" Text="Delete"  ImageUrl="img/Delete16.gif"                                                    ButtonType="ImageButton"
CommandName="Delete"  >
<ItemStyle Width="20px" />
</telerik:GridButtonColumn>

<ClientSettings EnableRowHoverStyle="True" AllowRowsDragDrop="True" >
 <ClientEvents OnCommand="Test" />
</ClientSettings>

... and I call Test like :

function Test(sender, args)

 var command = args.get_commandName();
 if (command == "Delete")
 { 
  var rowNo = args.get_commandArgument() ;
  alert(rowNo);
}
I cannot get row number.

But if I set :

<telerik:GridButtonColumn UniqueName="DeleteColumn" Text="Delete"     
CommandName="Delete"  >
<ItemStyle Width="20px" />
</telerik:GridButtonColumn>

<ClientSettings EnableRowHoverStyle="True" AllowRowsDragDrop="True" >
 <ClientEvents OnCommand="Test" />
</ClientSettings>

without ImageButton style, everything works good and I can get row number. Why ??

Regards
Krzysztof

1 Answer, 1 is accepted

Sort by
0
Vlad
Telerik team
answered on 24 Nov 2008, 09:12 AM
Hi Krzysztof,

Unfortunately you are right. We fixed this immediately and the fix will be part of our first service pack (middle of this week).

I've added 1000 Telerik points to your account.

Sincerely yours,
Vlad
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Tags
Grid
Asked by
Krzysztof
Top achievements
Rank 1
Answers by
Vlad
Telerik team
Share this question
or