473,386 Members | 1,763 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

data grid with stored procedure as a data source

Hi,
I'd like to use a datagrid with a

1. most grid's use SQL data adapters as a datasource. I'd like to use
a parametrized query into a stored procedure (specifically a
sqldatareader) instead of using the data adapter.

does anyone have any code samples that will do this?
I'm looking for gridname.datasource = mydatareader (if this is possible)
where the sqldata reader returns a result set from a parametrized stored
procedure.

2. I'd also like a code snip of leveraging the grid to perform a LIVE
update to the datasource (where the data source IS NOT A bound to a sql
server table). I'd actually like to have the modifications of the table
rows as input to save records in the table, but the VIEW that the grid
gives the user COULD be a join from 2 tables.
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 20 '05 #1
1 1765
* larry mckay <la***@larrymckay.com> scripsit:
I'd like to use a datagrid with a

1. most grid's use SQL data adapters as a datasource. I'd like to use
a parametrized query into a stored procedure (specifically a
sqldatareader) instead of using the data adapter.


If you don't get an answer here, you may want to post to this group:

NG for Windows Forms + databinding:

<news://news.microsoft.com/microsoft.public.dotnet.framework.windowsforms.dat abinding>

--
Herfried K. Wagner
MVP · VB Classic, VB.NET
<http://www.mvps.org/dotnet>

<http://www.plig.net/nnq/nquote.html>
Nov 20 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: pmud | last post by:
Hi, I need to display columns in a data grid based on 7 different queries. Now I have 32 questions: 1. Is it possble to have 1 single data adapter with 7 queries & 1 data set or do I need to...
1
by: Linda | last post by:
Hi, I'm new to asp.net and tryign to learn how to work with data grids. I'm retrieving data from a stored procedure and putting it in a data grid. I then want to be able to sort the data when...
5
by: tshad | last post by:
Is there a way to carry data that I have already read from the datagrid from page to page? I am looking at my Datagrid that I page through and when the user says get the next page, I have to go...
2
by: Fir5tSight | last post by:
Hi, I have a grid that displays a few columns of data obtained from a stored procedure. Now under certain condition, I'll need to add an additional column to the same grid whose data are...
3
by: Sam | last post by:
Hi All, I have a very strange issue with ms sql stored procedure and sqlDataReader and I hope that someone can tell me what's going on . I have an asp.net application which has one of its page...
1
by: sheenaa | last post by:
Hello Members, I m creating my application forms in ASP.Net 2005 C# using the backend SQL Server 2005. What i have used on forms :: ? On my first form i have used some...
4
by: =?Utf-8?B?UmludSBHb3BhbGFrcmlzaG5hIFBpbGxhaQ==?= | last post by:
Hi All, I have an application that fetch data thru a store proc and display in a datagrid, but after successful execution of proc the data grid is not visible.Please go thru the following code...
0
by: =?Utf-8?B?UGhpbCBKb2huc29u?= | last post by:
Hi, I have 2 gridviews on an asp.net 2.0 form. When I click select on a row in the first grid, in the GridView1_SelectedIndexChanged event I set the value of a textbox (with visibility set to...
6
by: insirawali | last post by:
Hi all, I have this problem, i need to know is there a way i cn use the data adapter's update method in this scenario. i have 3 tables as below create table table1{ id1 int identity(1,1)...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.