Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / General / August 2007

Tip: Looking for answers? Try searching our database.

Getting Other Data from SQLDataSource ?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
jobs - 10 Aug 2007 01:55 GMT
I have a GRIDVIEW I have bound to an OBJECTDATASOURCE that has the
select pointing to a class method that uses ADO to grab a dataset from
SQL Server Stored Procedure.

One of the columns that comes back I am not interested for the Grid,
But I would like the first ROW's value for a label.

I could do another IO to go get this, but Is there any way I can
extract this data from the DATASOURCE directly in the Codebehind?

Thanks for any help or information.
Eliyahu Goldin - 10 Aug 2007 07:46 GMT
Why are you using ObjectDataSource if the database is Sql Server?
SqlDataSource provides property DataSourceMode that can be used for getting
a DataTable object from the datasource.

Look here for details:

How to get DataTable out of SqlDataSource
http://msmvps.com/blogs/egoldin/archive/2006/12/27/how-to-get-datatable-out-of-s
qldatasource.aspx


Signature

Eliyahu Goldin,
Software Developer & Consultant
Microsoft MVP [ASP.NET]
http://msmvps.com/blogs/egoldin

> I have a GRIDVIEW I have bound to an OBJECTDATASOURCE that has the
> select pointing to a class method that uses ADO to grab a dataset from
[quoted text clipped - 7 lines]
>
> Thanks for any help or information.

Rate this thread:







Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.