Datacontrol and Access

seancampbellseancampbell Pennsylvania, USA
I recently wrote a program that uses a Datacontrol to manipulate a database.

My problem is that I would like to have this program work on any computer around, but unfortunatly the Database will not work on any computer except the one it was made on.

I guess what I really am looking for is advice on whether or not to change my Datacontrol to a different style of Datamanipulation. I have considered making an installing program that will create the database on your computer with your version of access, but I don't know how to go about this, and I don't know if this is even the right path to take.

I am an ameture programmer (its my major in college), and I havn't done any writing before for money. This program that I made was submitted in school for a project, but I am looking to improve it for my own use and I would like to be able to make this improvement.


Any advice will really help me. Thank you in advance for even reading my message :),
Sean Campbell

Comments

  • : I recently wrote a program that uses a Datacontrol to manipulate a database.
    :
    : My problem is that I would like to have this program work on any computer around, but unfortunatly the Database will not work on any computer except the one it was made on.
    :
    : I guess what I really am looking for is advice on whether or not to change my Datacontrol to a different style of Datamanipulation. I have considered making an installing program that will create the database on your computer with your version of access, but I don't know how to go about this, and I don't know if this is even the right path to take.
    :
    : I am an ameture programmer (its my major in college), and I havn't done any writing before for money. This program that I made was submitted in school for a project, but I am looking to improve it for my own use and I would like to be able to make this improvement.
    :
    :
    : Any advice will really help me. Thank you in advance for even reading my message :),
    : Sean Campbell
    :
    Sounds like the data source for your data control needs to be modified so that anyone can use your application. You might remember when you made your connection to your data that you specified what and where it is. This may not be consistent with someone elses installation and therefore will not work. There are probably a couple of work arounds. You could make sure that the data is stored in exactly the same place on for every computer that may access it. Or have some sort of variable declared that can be used to find the source of the data. This means that another computer with an installation of your program can locate the data files even if they are in a different place than that of your own installation.

    If you used the data environment to provide the source for your data control you need to modify the connection property

    dataenvironment1.connectionstring = "MyConnection"

    By changing the value of MyConnection you can specify different locations for different installations.

    Hope this helps you a little more.

    John ;-)
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

In this Discussion