Hello all,

I have an ImageButton within a TemplateField of a GridView. I would like to use the Command Event of this ImageButton to update some items in a database. However, I want to pass in two variables to this event, a username, and an integer value.

The UserName is easy enough, as this is a bound field within the gridview, however, the Integer is decided by the user at run time, by typing it into a text box. Is there anyway to pass the TextBox.Text Property into the CommandArgument Property of the Command Event?

i.e. something like CommandArgument='<% TextBox.Text %>

Thank you for your help!!

Gary