Thanks for getting back to me Bob. Unfortunatly though I need to evaluate the entire collection against another collection. I do not see a way to set a global element. I thought onPreRender would be the spot but it doesn't seem that the controls are bound yet there. I thought this would be an easy thing to do. ;-) That's what I get for assuming, right. Let me ask you there do you know at what point in the Page rendering cycle do the controls get bound?
Travis D. Falls | Consultant RAFT.Net IT | 860.547.4070 | [EMAIL PROTECTED] -----Original Message----- From: [email protected] [mailto:[EMAIL PROTECTED] Behalf Of Bob Filipiak Sent: Friday, June 03, 2005 4:01 PM To: [email protected] Subject: Re: [AspNetAnyQuestionIsOk] DataGrid Item Take a look at OnItemDataBound and OnItemCreated methods. You might be able to use global variables for your comparisons. ----- Original Message ----- From: "Falls, Travis D (HTSC, CASD)" <[EMAIL PROTECTED]> To: <[email protected]> Sent: Friday, June 03, 2005 3:36 PM Subject: [AspNetAnyQuestionIsOk] DataGrid Item >I have two datagrids that are bound to two datatables. One is the original > data and another is the modified data. I want to use the onPreRender to > check these two grids and if the destination item is different highlight > it > in the modified grid by assigning a CSS class to the span tag. Does > anyone > know how I can interrogate the data of a datagrid right before render and > set the CSS for the span tag? Thanks. > > protected override void OnPreRender(EventArgs e) { > foreach(DataGridItem dataGridItem in Destinations_A.Items){ > > ((HtmlControl)dataGridItem.FindControl("Destination_A"));//to get at the > span tag with the data in it > } > } > > > > Travis D. Falls | Consultant RAFT.Net IT | 860.547.4070 | > [EMAIL PROTECTED] > > > ************************************************************************* > PRIVILEGED AND CONFIDENTIAL: This communication, including attachments, is > for the exclusive use of addressee and may contain proprietary, > confidential and/or privileged information. If you are not the intended > recipient, any use, copying, disclosure, dissemination or distribution is > strictly prohibited. If you are not the intended recipient, please notify > the sender immediately by return e-mail, delete this communication and > destroy all copies. > ************************************************************************* > > > > > Yahoo! Groups Links > > > > > > > > Yahoo! Groups Links Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/AspNetAnyQuestionIsOk/ <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/
