Hi, in order to format my web page, I'm starting to use Flow layout so
using html tables to space out controls, etc. When using grid layout,
the following worked when it was just a datagrid. I know I need to
somehow refer to the datagrid within the html table cell, but can't
figure out how.
THANKS!
Public Sub dgConfirmOrder_ ItemDataBound(B yVal sender As System.Object,
ByVal e As System.Web.UI.W ebControls.Data GridItemEventAr gs) Handles
dgConfirmOrder. ItemDataBound
Select Case e.Item.ItemType
Case ListItemType.Al ternatingItem, ListItemType.It em
'Calculate total for the field of each row and alternating row.
myTotal += CDbl(e.Item.Cel ls(3).Text)
'Format the data, and then align the text of each cell to the right.
e.Item.Cells(3) .Text = Format(CDbl(e.I tem.Cells(3).Te xt),
"##,##0.00" )
e.Item.Cells(3) .Attributes.Add ("align", "right")
Case ListItemType.Fo oter
'Use the footer to display the summary row.
e.Item.Cells(2) .Text = "Total"
e.Item.Cells(2) .Attributes.Add ("align", "left")
e.Item.Cells(3) .Attributes.Add ("align", "right")
e.Item.Cells(3) .Text = myTotal.ToStrin g("c")
End Select
End Sub
Thanks, Kat
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!