Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Datagrid Control > How do I list item in a templatecolumn?

Thread Tools

How do I list item in a templatecolumn?

Posts: n/a
I have a pushbutton in templatecolumn in a DataGrid. I can iterate
through some of the rows in the datagrid with:

sub alert_inactive(sender As Object, e As DataGridCommandEventArgs)
dim item as datagriditem

For Each item In sender.Items
response.write("<br>The answer is: <BR>" & item.Cells(1).Text & " " &
item.Cells(2).Text & " " & item.Cells(3).Text)
Next item
end sub

However, in the DataGrid there is this:

<asp:TemplateColumn HeaderText="Completed"
<asp:button id="butCompleted" causesvalidation="false"
text="Completed?" commandname="Delete" Runat="server" />
<asp:TemplateColumn HeaderText="Completed"
<asp:button id="butChecked" commandname="Delete"
causesvalidation="false" text="Checked?" Runat="server" />

I cannot figure out how to get the ID of these two buttons in this

Thank for any help.
Reply With Quote

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: How include a large array? Edward A. Falk C Programming 1 04-04-2013 08:07 PM
why writing list to file puts each item from list on seperate line? Python 5 12-31-2005 05:21 AM
why writing list to file puts each item from list on seperate line? Python 0 12-31-2005 04:22 AM
List index method for complex list item types? Python 4 12-31-2005 03:44 AM
Change style of a single row of the item list of datagrid, based on a field value of current item... QUASAR ASP .Net Datagrid Control 6 01-17-2004 07:46 PM