[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Deploying an Application

Posted on 2006-04-02
2
Medium Priority
?
305 Views
Last Modified: 2010-05-01
I have a vb6 application that I am deploying. The application uses a system DSN. When I package and deploy the application, and install it on a client, the application can not find the datasource. Is there a way to resolve this when deploying the application? Do I have to re-create the DSN on the client. Re-creating wouldn't be a good solution because it would be tedious when deploying to several clients.
0
Comment
Question by:Gary2397
2 Comments
 
LVL 17

Accepted Solution

by:
Muhammad Khan earned 2000 total points
ID: 16357370
YEs... you need to create a DSN on every client machine before your application can use it...

easy way is to create it dynamically.. or use OLEDB ConnectionString within the application.. .

ODBC Example

connectionString = "driver={Microsoft Access driver (*.mdb)};DBQ="c:\company.mdb"
myConnection.Open(connectionString)


OLEDB Example

connectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=c:\company.mdb"
myConnection.Open(connectionString)
0
 
LVL 9

Expert Comment

by:pradapkumar
ID: 16357639
In addition
U can use ODBCDialog Template form which was available readily in the vb6 to read the parameters from the users. So, In future if u wish to change the server name u can easily assign the file path to there and change it easily.
Or u can store ur connection string in Registry and read it from there instead of staticly storing in your form.
0

Featured Post

Vote for the Most Valuable Expert

It’s time to recognize experts that go above and beyond with helpful solutions and engagement on site. Choose from the top experts in the Hall of Fame or on the right rail of your favorite topic page. Look for the blue “Nominate” button on their profile to vote.

Question has a verified solution.

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

Introduction While answering a recent question (http://www.experts-exchange.com/Q_27402310.html) in the VB classic zone, I wrote some VB code in the (Office) VBA environment, rather than fire up my older PC.  I didn't post completely correct code o…
The debugging module of the VB 6 IDE can be accessed by way of the Debug menu item. That menu item can normally be found in the IDE's main menu line as shown in this picture.   There is also a companion Debug Toolbar that looks like the followin…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
Suggested Courses
Course of the Month19 days, 5 hours left to enroll

834 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