Hi Joe
This button will be placed in a Datarepeater ctrl. I want to use the
information thats included in the CommandArgument to supply me with
information like: how many times this item has been clicked and the ID of
the selected content of the Datarepeater. I can not use the CommandName for
this since I need it allready to supply me with more information from the
database.
I've found a way around this by just get the ID and execute a database
lookup, read the field with the stored information on how many times it has
been clicked, add 1 and write the new total of the click counter back to the
database.
I just thought it would be faster and easier to supply the value of the
click counter in the Datarepeater, and I really think there must be a way to
include two information strings in the CommandArgument.
Jan
"Joe Molloy" <mo********@hotmail.com> schrieb im Newsbeitrag
news:OQ**************@TK2MSFTNGP10.phx.gbl...
I think we need to see the bigger picture here Jan - what are you trying
to achieve with this behaviour - maybe we can spot alternative approaches.
Joe
"Jan Vetterli" <ja**@yahoo.com> wrote in message
news:10***************@fuchs.cyberlink.ch... hi,
I'm wondering how I can achieve a button with a CommandArgument thats
dynamicly created from two or more DataBinder values, seperated with a
";" so I can split the information up afterwards.
I've tried this (on the HTML page):
<asp:Button ID="NewButton" Runat="server" Text="New"
CommandName = "New"
CommandArgument ='<%# DataBinder.Eval(Container.Item, "ID")%> & ";"
& <%# DataBinder.Eval(Container.Item, "Name")%>'
</asp:Button>
With this code, I'll alway get an error msg. Can anybody help, please?
Thanks
Jan