Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

How do I copy a Typed Dataset to another project

Posted on 2007-12-04
3
Medium Priority
?
1,729 Views
Last Modified: 2011-09-20
Greetings,

I have a complex Typed Dataset that I created in a Visual Studio 2005 C# project.

I would like to copy this typed dataset to and use it in another project.

What is the best way to do this?

Bob
0
Comment
Question by:bobsegrest
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 13

Expert Comment

by:SameerJagdale
ID: 20409267
when you create a typed dataset, it create 3-4 files. The only important file is .designer file which contains classes. You can add a new code file, name it to <dataset>.cs and copy the contents of .designer file to it. Now delete the original dataset (it deletes all the relevant files).
You can now use the code file as a dataset.

hope it helps.
0
 
LVL 7

Accepted Solution

by:
badbearontour earned 2000 total points
ID: 20409750
I usually copy all the files dataset files over to the new project

Then include the file in the new project.... open the dataset and close it again. that recompiles the classes code.

The only change then is to correct the namespace in the <dataset>.cs file to whatever it should be in the new application.

BB
0
 
LVL 13

Author Closing Comment

by:bobsegrest
ID: 31412749
The component I had missed was the change in name space.
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes a simple method to resize a control at runtime.  It includes ready-to-use source code and a complete sample demonstration application.  We'll also talk about C# Extension Methods. Introduction In one of my applications…
Introduction Hi all and welcome to my first article on Experts Exchange. A while ago, someone asked me if i could do some tutorials on object oriented programming. I decided to do them on C#. Now you may ask me, why's that? Well, one of the re…
Please read the paragraph below before following the instructions in the video — there are important caveats in the paragraph that I did not mention in the video. If your PaperPort 12 or PaperPort 14 is failing to start, or crashing, or hanging, …
This lesson discusses how to use a Mainform + Subforms in Microsoft Access to find and enter data for payments on orders. The sample data comes from a custom shop that builds and sells movable storage structures that are delivered to your property. …

610 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question