Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > GridView RowCreated Handler Issues

Reply
Thread Tools

GridView RowCreated Handler Issues

 
 
bigbrorpi@gmail.com
Guest
Posts: n/a
 
      04-24-2006
I'm having a problem with a Gridview bound to an objectdatasource. I've
created a handler for onRowCreated with something as simple as:

msgbox(e.row.cells(1).text)

When the page loads, I see all of the data rows from my datasource, but
the e.row.cells(1).text comes up blank for every row except the header
and footer.

Does anybody see what I might be missing here?

Thanks

 
Reply With Quote
 
 
 
 
Jeff Dillon
Guest
Posts: n/a
 
      04-24-2006
Well, for one thing, you can't use msgbox, it's on the server!

Perhaps you meant response.write

What does the data look like coming from the datasource? Is it a SQL query?
What does the query return in Query Analyzer, if so

Jeff

<(E-Mail Removed)> wrote in message
news:(E-Mail Removed) oups.com...
> I'm having a problem with a Gridview bound to an objectdatasource. I've
> created a handler for onRowCreated with something as simple as:
>
> msgbox(e.row.cells(1).text)
>
> When the page loads, I see all of the data rows from my datasource, but
> the e.row.cells(1).text comes up blank for every row except the header
> and footer.
>
> Does anybody see what I might be missing here?
>
> Thanks
>



 
Reply With Quote
 
 
 
 
fiendiest fiendiest is offline
Junior Member
Join Date: Oct 2007
Posts: 1
 
      10-25-2007
I think you may have added a handler to RowCreated, which is only fired when the header and footer are created.
But if you are data binding you need to add a handler to RowDataBound, which is fired for every row as it is bound.

Xopher
 
Reply With Quote
 
 
 
Reply

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
Is RowCreated event good for removing columns from gridview footer? Bogdan ASP .Net 0 09-29-2008 06:14 PM
Gridview Rowcommand / Rowcreated question benji ASP .Net 0 02-29-2008 02:30 AM
GridView - RowCreated EventHandler doesn't work if page IsPostBack Paul ASP .Net 2 04-29-2007 01:48 PM
Gridview RowCreated - way to change just first row command text? K B ASP .Net 1 06-06-2006 03:56 PM
InputAttributes in RowCreated (gridview) Pipo ASP .Net 1 04-01-2006 05:28 PM



Advertisments