Cannot generate dataset

S

Skip

When I select 'Generate Dataset' on the oleDbDataAdapter I get the message:

'Visual Studio could not create an instance of xxx.DataSet1. Confirm the
class name is a valid DataSet class.'

I haven't been able to find an answer to this exact problem in any
discussion groups, but I read somewhere that it could be due to the
database pathname having spaces in it. This didn't fix the problem.

After creating the oleDbDataAdapter and oleDbConnection I can 'Preview
Data' once, but after that I get the above error message. After I delete
DataSet1.xsd from the Solution Explorer I can preview the data again
(but only once).

Any thoughts?
 
M

Mohamoss

Hi Skip!!
That error says there is a problem creating an instance of the dataset
(not to generate a new dataset) this is something different form error
generating the dataset it self . what I guess you have here is that you
are trying to create an instance of a dataset while you are using a name
that there is no dataset class.
Mohamed Mahfouz
MEA Developer Support Center
ITworx on behalf of Microsoft EMEA GTSC
 
S

Skip

But what does this error mean? The wizard creates a class called
DataSet1. Do I need to create an additional class for the dataset?
 
M

Mohamoss

do you mean create two clases of the dataset !! ( i guess there is no
meaning to do that ) . but i you want to create classes of the dataset (
instances) . then you can't use wizard from that you do it from with in
your code
mydastsetcalssname instance_name = new mydastsetcalssname();
Mohamed Mahfouz
MEA Developer Support Center
ITworx on behalf of Microsoft EMEA GTSC
 

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