473,779 Members | 2,041 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Dataset or datasource control?

Hi all,

Having moved from dotnet V1.1 to V2 I am having some difficulty
understanding the new data access methods that seem to be preferred.
In V1.1 the dataset did everything that I needed, and now it seems that
the preferrence is the datasource control! aaarrrrgggg!

I have followed several example of how to manage the modification and
deletion of data from a gridview on as asp.net page and I have to say I
am impressed with its simplicity, however, can anyone point be to a
post or other online article that has the details of how to do this
using a dataset instead of a datasource?

I can bind my dataset to the gridview, but the entire edit/delete
functionality has gone. What am I missing?

Many thanks,

Jason

May 1 '06 #1
3 1304
Hi Jason,

The topic is broad, but here is a little hint: you can bind a Dataset
to an ObjectDataSourc e. What I am not sure at this moment is if it must
be a typed dataset, I think so. There might be other ways to go, but
this should work.

In terms of the recommended best practices, arquitecture or paterns,
let me tell you that after months of working with ASP 2.0 I have found
that there is many many ways to go - there isn't yet a "main"
arquitecture. You may want to look at the Start Kit's in the ASP.NET
web site to gather some ideas and select what is best for your
application.

Good luck!
Good luck.

May 1 '06 #2
Jason,
Not to sound like a broken record here, but have you looked at the
Quickstarts?
ASP.NET 1.1
http://samples.gotdotnet.com/quickst...formsauth.aspx

ASP.NET 2.0
http://www.asp.net/QuickStart/aspnet...formsauth.aspx

This also installs with the product.
Peter

--
Co-founder, Eggheadcafe.com developer portal:
http://www.eggheadcafe.com
UnBlog:
http://petesbloggerama.blogspot.com


"Jason James" wrote:
Hi all,

Having moved from dotnet V1.1 to V2 I am having some difficulty
understanding the new data access methods that seem to be preferred.
In V1.1 the dataset did everything that I needed, and now it seems that
the preferrence is the datasource control! aaarrrrgggg!

I have followed several example of how to manage the modification and
deletion of data from a gridview on as asp.net page and I have to say I
am impressed with its simplicity, however, can anyone point be to a
post or other online article that has the details of how to do this
using a dataset instead of a datasource?

I can bind my dataset to the gridview, but the entire edit/delete
functionality has gone. What am I missing?

Many thanks,

Jason

May 1 '06 #3

I would concur the "bind strongly typed dataset to the ObjectDataSourc e".

After a few experimentation s, it worked best for me.

My main reason is that:

You need to bind GridViews to a SqlDataSource or ObjectDataSourc e.
N-tiered answers the question (for me) about whether to use the
SqlDataSource or the ObjectDataSourc e (object being the "winner").

My project runs a query to get 1000+ rows. But after the user gets that
data, they sort,page on it for several reps...before going onto another
(new) query.

Thus I populate the strongly typed DS , cache it. and bind it to the
ObjectDataSourc e as the user navigates the GridView.


"Neutrino" <ne*********@ya hoo.com> wrote in message
news:11******** ************@y4 3g2000cwc.googl egroups.com...
Hi Jason,

The topic is broad, but here is a little hint: you can bind a Dataset
to an ObjectDataSourc e. What I am not sure at this moment is if it must
be a typed dataset, I think so. There might be other ways to go, but
this should work.

In terms of the recommended best practices, arquitecture or paterns,
let me tell you that after months of working with ASP 2.0 I have found
that there is many many ways to go - there isn't yet a "main"
arquitecture. You may want to look at the Start Kit's in the ASP.NET
web site to gather some ideas and select what is best for your
application.

Good luck!
Good luck.

May 1 '06 #4

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

Similar topics

2
1463
by: David Whitfield | last post by:
Hi All - I am an experienced ASP developer but am new to ASP.NET and the .NET framework and am trying to learn how to access datasets. When I try to build the following page, I get the errow below. I've reviewed my code over and over and looked for similar errors/information on the web but I can't seem to find what the problem is, and therefore I can't come up with a solution. Can anyone help me? Thanks in advance... Page (am...
4
3479
by: Eric | last post by:
Hi, can anyone guide me throught this: In my application, I have a global DataSet. I then run FTP processes in up to 10 simultaneous threads and each thread calls progress events in the main application. When a progress event is called, the main application writes the input to the global DataSet. Occasionally, the DataSet writes itself to an XML file. This all works fine. - But you can't see what's going on.
3
1533
by: MajorTom | last post by:
Hello everybody, I need help on how to use the same datase in two different form, this is the scenario: at the first form I load a big dataset (ds1) for short, but I not want to load it again at the second form at some point I use a second form Form f = new FormX(); f.ShowDialog();
5
3703
by: Jason | last post by:
I am having problems understanding how to access a datasource only once, fill a single dataset, and then reference that dataset multiple times through different user controls(ascx) found on the same page. My main page(aspx) contains multiple user controls. The main page also contains a publicly declared dataset. At the first instance of needing data I call (from an ascx) a function that fills the dataset and then returns it to the...
3
3517
by: Bill | last post by:
I have a seating chart web form that has over 50 entry field controls (tables/booths) where I use a DropDownList box to select a single company name from a single large list of organizations (200 plus conference attendees). All web form datavalues will be one of the same 200 organizations in this list. I would like to avoid creating 50 separate exact copies of the same DataSet object. Can you help? Q. Exactly how do I use the same...
1
4424
by: Greg Cyrus | last post by:
Hi, i have created a function to open a Databse by OLEDB and fill it into a System.Data.DataSet-Objekt by oleDBAdapter.Fill-Mehtod.. Now I want to assign this DataSet to a normal Repeater-Control. This Repeater-Control accepts anything like System.Collections.IEnumerable for a DataSource. I have tried to copy the System.Data.Dataset into a DataView-Objekt (System.Collections.IEnumerable) but I guess there must be some other and
1
1745
by: Sean | last post by:
What is the best way to access the Underlying data of a DataGrid. I have two SQL tables joined and display some data from both, but I want to be able to on clicking of a row bring up a form that displays all the data. I can come up with some round about ways of doing it, but is there a property of the DataGrid that will make it easier and quicker to do? Thanks.
4
4923
by: Brad Baker | last post by:
I'm going a little crazy :) I'm trying to bind a repeater control to a dataset on page load using the following code: if (Request.QueryString != null) { string customerid = Request.QueryString; //open connection SqlConnection m_conn = new SqlConnection("Server=server; Database=database; UId=username; Pwd=password");
4
5934
by: John Sheppard | last post by:
Hello there I was wondering if anyone could help me, I am trying to pass a typed dataset to a dialoged child form by reference. I have binding sources sitting on the child form. So to refresh them I just set their datasource. I am guessing this is probably what is causing the problem. Is there a better way to do this? Anyway this all works happily and things show up when the record already exists but I have 2 problems ; 1) When I add...
1
2802
by: =?Utf-8?B?R3JlZw==?= | last post by:
Most of my background is with VB.Net and WinForm development and I am in the process of migrating my skills to C# Web Based development. I've come across something I'm not quite sure how I should handle. I have a web-page with a asp:GridView on it. In hte Page_Load event of the page, I create a Dataset and Bind it to the grid as follows: myGridView.DataSource = dsMyDataSource; myGridView.DataBind();
0
9636
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9474
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10306
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10074
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9930
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
6724
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5373
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5503
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
3
2869
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.