Solved

Update SQL timesheet program

Posted on 2008-10-21
5
229 Views
Last Modified: 2013-11-27
Some years ago a predecessor wrote a program in VB6 for our company to use for timesheets. It stores the entries in an SQL 200 db. We have installed a new SQL 2005 and want to point the program to the new SQL server but I do not see where to change that info. The program does not add an ODBC connection to the desktops. I have Visual Studio installed on my PC but have not found where the program gets pointed to the old SQL server. What file should I be looking for?
0
Comment
Question by:LarryDAH
  • 2
  • 2
5 Comments
 
LVL 42

Expert Comment

by:dqmq
ID: 22769088
Scan the code for a "connection" object.  The connection string could be hardcoded in the code or it could be stored in a configuration file or who-knows-  what other inventive places.  But find where the code is opening a connection and  you should be on your way.  

0
 

Author Comment

by:LarryDAH
ID: 22769357
It seems that the version of Visual Studio that I have will not open the files as a project altho it will open any given file. This could take some time, know of any work around?
0
 
LVL 18

Expert Comment

by:mdougan
ID: 22769370
Yes, typically, connection logic would be stored in a global Basic module  (.BAS file), so that it could be called or used from all other code in the application.  You can search for .Open   too, or ADO, or OleDB.

If no ODBC DSN was created on the client machines, then the connection string is either hardcoded in the program, or read in from the registry, or an INI file of some sort.
0
 
LVL 18

Accepted Solution

by:
mdougan earned 500 total points
ID: 22769400
Yes, you can download for free a tool called TextPad.  This is a basic Text Editor program.  It has a feature called Find In Files.  You would click on Search|Find In Files   then specify the root directory for your project,  *.* for file type,  the word you want to search for as the search term... don't check the Compare Case checkbox or the Whole Word checkbox... if there is an option to check subfolders, check that.  Then search

You can try the same thing with the Search tool under the Windows Start Button, but that never works very well for me when I'm looking for text inside of files.
0
 

Author Closing Comment

by:LarryDAH
ID: 31508382
Textpad let me view the code but I could not find the entries that I needed to fix. I will have to go another route to fix the issue.
0

Featured Post

NAS Cloud Backup Strategies

This article explains backup scenarios when using network storage. We review the so-called “3-2-1 strategy” and summarize the methods you can use to send NAS data to the cloud

Question has a verified solution.

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

Slowly Changing Dimension Transformation component in data task flow is very useful for us to manage and control how data changes in SSIS.
Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
Via a live example, show how to shrink a transaction log file down to a reasonable size.
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…

895 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

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now