By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
448,967 Members | 1,554 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 448,967 IT Pros & Developers. It's quick & easy.

FindBy<> method in Typed DataSet.

P: n/a
Dear Group:

A question regarding the behavior of the Visual Studio.NET.

When I drag the "Customers" table in "Northwind" database on Server Explorer
to my web page, then select the DataAdapter object, and then right-click to
"Generate DataSet.." The C# class source file for this typed DataSet would
have the following method

public CustomersRow FindByCustomerID(string CustomerID) {
return ((CustomersRow)(this.Rows.Find(new object[] {

in the CustomerDataTable class. It's quite convenient to use that to do key
value search.

But if I have an XML file, and use XML Schema Designer to create the schema
for that XML file, select the primary key on the schema, and save the files,
the generated C# class source file would *not* have that "FindBy<key name>"
method in it.

Can someone advice how does VS.NET determines when to create that "FindBy"
method based on the schema attributes?


from Henry
Nov 18 '05 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.