Using Enterprise Library DAAB with Strongly Typed DataSet

G

Guest

I have been developing applications with Java for quite a while but I am new
to .NET development. I am trying to learn the ".NET way" of creating Strongly
Typed Objects from a database. The Enterprise Library seems pretty close to
what I am used to in Java but I am not sure how to create strongly-typed
DataSets. I see that I can use the LoadDataSet method from a
Microsoft.Practices.EnterpriseLibrary.Data.Database but I am not clear on how
I map my relational model to the strongly-typed DataSet. Can anyone provide
an example or guidance?

Thanks
 
M

Mythran

David said:
I have been developing applications with Java for quite a while but I am
new
to .NET development. I am trying to learn the ".NET way" of creating
Strongly
Typed Objects from a database. The Enterprise Library seems pretty close
to
what I am used to in Java but I am not sure how to create strongly-typed
DataSets. I see that I can use the LoadDataSet method from a
Microsoft.Practices.EnterpriseLibrary.Data.Database but I am not clear on
how
I map my relational model to the strongly-typed DataSet. Can anyone
provide
an example or guidance?

Thanks

Easy Way :)

Right-click on the project you want to add the strongly-typed DataSet to,
click Add New Item. Select DataSet from the list and give it a name, then
click on the Ok (or whatever the button name is to accept). You can
manually create the table (element) using the designer that is opened (if
not opened, double-click the dataset you added to the project). An easier
way would be to open the Server Explorer tool window, connect to the
database, then drag-n-drop the table you want to be added to this DataSet.

This is assuming all default options are still intact :)

Mythran
 
G

Guest

Thank you for your help. I should have been more specific. I have been able
to use strongly-typed DataSets directly but I have not been able to create
them with the Enterprise Library Data Access Application Block (DAAB). I can
also create untyped DataSets just fine using the Enterprise Library DAAB. I
am looking for an example that shows how to use the Enterprise Library DAAB
to create a strongly typed DataSet. Ideally, that DataSet would have some
form of simple relation like a customer to an address or something similar.

Thanks again
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top