Link to home
Start Free TrialLog in
Avatar of Leonard Gojer
Leonard GojerFlag for United States of America

asked on

How to Add a Data Source in Visual Studio C# Without Errors

I am developing a program in Visual Studio C#. I am trying to add a data source to it so
that it can have a database displayed in a DataGrid. When I go to "Add Data Source" and follow the steps, I get the following error: "Could Not Retrieve Schema Information For Table or View". The database is in an .mdb file in the same directory as the program. Can anyone help with this error?
Avatar of Bob Learned
Bob Learned
Flag of United States of America image

What version of Access are you working with?

What version of Visual Studio.NET are you using?
Avatar of Leonard Gojer

ASKER

Access 2003.
Visual Studio 2010 Premier.
To make sure that I understand what you are referring to, are you talking about the Data > Add New Data Source menu option?
Yes.
Hello,
I see that my question has stumped you. I think maybe that I should subscribe to some other service as a way of getting this question answered, because it's kind of an advanced C# question on a relative scale. Can you recommend some service to me that would be such a resource, (perhaps charging under $30/month)?

I am trying to develop this project for a commercial application, but I can't afford a support contract from Microsoft.
I don't work with Access very much, and I have Access 2010.  Also, I don't use the Add Data Sources dialog, so I needed to review.  Sometimes I  get involved in too many questions.  Lastly, I have my own production issues to take care of, which means I can't dedicate all my time.

Did you try the same process with different databases?  Is this a problem with the computer, or the database structure?
I checked your question and it has the same problem with any database that I create.

I am going to be away from this computer for a couple of days, so you won't have to attend to this problem until sometime like Monday.
Where are the databases that you are trying to connect to with the dialog?  I was assuming local machine, where you should have full rights.  The dialog needs access rights to the target file.

Is this Windows 7, Windows Vista, or Windows 2008 Server?
I have to try looking into that when I get there, but I am not there right now, so I will
talk to you on Monday. The machine in question is a virtual machine on a server running
Windows XP.
Hello, I am back from my trip out of town.

I have several books on C#, but I haven't read them thoroughly. It could be that the answer to this question is in one of those books.

I'd like you to help me to understand how I go about looking up this question in one of those books, so that I can be on my own with respect to this problem. Maybe you can give me some "clues" that will get me started to fix it for myself.
That error suggests that you don't have access rights to the database.  The dialog is trying to get information, but doesn't have the necessary security permissions.

What operating system are you working with on your virtual machine?

What are you using for your virtual machine?
The virtual machine is VMWare running Windows XP.
ASKER CERTIFIED SOLUTION
Avatar of Bob Learned
Bob Learned
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I am going to close this question.