Hi all...

Someone give me the difference between typed dataset and untyped dataset..

Regards,
Balagurunathan S

Recommended Answers

A typed dataset is a custom class generated for your project by Visual Studio that makes common jobs easier. It adds things like named properties that match column and row data in the tables. It's generated code and not a part of .NET, so you can't use typed datasets without …

Jump to Post

All 2 Replies

A typed dataset is a custom class generated for your project by Visual Studio that makes common jobs easier. It adds things like named properties that match column and row data in the tables. It's generated code and not a part of .NET, so you can't use typed datasets without Visual Studio unless you copy all of the code and manually customize it for your project. An untyped dataset is an object of the DataSet class. It's a part of .NET and you can use it even if you don't have Visual Studio.

Typed Dataset:

s = dsCustomersOrders1.Customers(0).CustomerID

Untyped Dataset:

string s = (string) dsCustomersOrders1.Tables["Customers"].Rows[0]["CustomerID"];

typed dataset is generally used as it is easy to use and moreover gives errors at compile time...compared to untyped which gives on run time

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.