Here is my problem.

I'm creating a program for my workplace which stores hours worked, calculates pay and all that stuff.

Problem being, the database will be accessed through the network and i want to be able to select the database from an openfile dialog on first use to locate the database. On every program start up it then would have the database location stored within the program itself.

Now, the reason for the post;

What is the best way of doing this?

There are many different ways of doing the same thing in programming, which is the most practical of storing application settings?

Thank you in advance


ok: update!

I've decided to use a .cfg file and using 'streamwriter' to create it.

I've used the following code to create my file:

Using sr As StreamWriter = New StreamWriter("dbpath.cfg")
sr.Write("db =" & db)
End Using

Im using pretty much the exact same code in form_load to read the file, but am unsure how to get the program to read whats in the .cfg as actual code.

Any ideas please?