sorry bout this, i had a brain cramp. the datasource was using a dataview of
the typed dataset. problem solved.
"rodchar" wrote:
> hey all,
>
> DataRowView drv = (DataRowView)((GridViewRow)lbl.NamingContainer).DataItem;
>
> i found this snippet on the net which works correctly in its context. It's
> datasource is coming from a Typed DataSet.
>
> Well, i modified the GridView's DataSource to use an UnTyped DataSet but i'm
> getting an error saying
> "Unable to cast object of type 'System.Data.DataRow' to type
> 'System.Data.DataRowView'.
>
> Can someone please confirm why this is so? or if this makes any sense?
>
> thanks,
> rodchar
>
>
|