Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / XML / August 2007

Tip: Looking for answers? Try searching our database.

Generate typed DataSet from XML or create typed DataSet from xsd?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
DC - 24 Aug 2007 16:51 GMT
Hi,

I can easily create an xsd from an xml file in Visual Studio 2005. But
I want a typed DataSet, so is there an option to create that typed
DataSet from the xsd or the xml file? I need many such typed DataSets
so I don't want to create them from scratch.

On a sidenote: I am loading the XML from http, I transform it via xslt
and then load the result into a typed DataSet. I think I am doing a
lot of inefficient things. I am always having trouble with "how to get
a reader / writer here" and "what to pass to this readxml there" so I
end up reading stuff into stringbuilders and streams and so on and on.
The Xml classes are very complex and I don't use them that often.
Maybe just coincidentally somebody has an example for this scenario...

TIA for any hints,
Regards
DC
Martin Honnen - 24 Aug 2007 17:16 GMT
> I can easily create an xsd from an xml file in Visual Studio 2005. But
> I want a typed DataSet, so is there an option to create that typed
> DataSet from the xsd or the xml file? I need many such typed DataSets
> so I don't want to create them from scratch.

The xsd.exe tool, part of the .NET framework SDK, can create typed
datasets from xsd schemas using e.g.
  xsd.exe schema.xsd /dataset
see <URL:http://msdn2.microsoft.com/en-us/library/x6c1kb0s(VS.80).aspx>

Signature

    Martin Honnen --- MVP XML
    http://JavaScript.FAQTs.com/

DC - 27 Aug 2007 17:53 GMT
> > I can easily create an xsd from an xml file in Visual Studio 2005. But
> > I want a typed DataSet, so is there an option to create that typed
[quoted text clipped - 10 lines]
>         Martin Honnen --- MVP XML
>        http://JavaScript.FAQTs.com/

Thank you Martin, that works exactly as I was hoping.

Regards
DC

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.