![]() |
#1
|
|||
|
|||
![]()
Word VBA newbie...
User is running an application that uses MS SQL server. The program can either be using a test database on the back-end or a production database. While in the program they start Word. Word is the way they get data into certain parts of the program since they are using Word to create a report that will be stored in the database. I have written a .dotm that is in the users Word StartUp folder. I query the database using macros in the macro enabled template. The issue is that someone could open Word using either the test database or the production database on multiple servers. Since my application queries the database to get certain information I need to know whether they are using the test database or the production database and which server they are located on. I can tell by the name of the database whether they are in the test database or the production database. The test database and production databases could be on the same server or a different server. Is there a way to use VBA and find out the name of any open SQL databases and the server they are located on? That way I could open the correct database to get the information I need. Thank you... |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
![]() |
pemartins | Excel | 16 | 02-24-2014 11:39 PM |
![]() |
zuzullo | Outlook | 3 | 09-08-2011 12:34 AM |
unable to open .RTF files in server machine from client machine | Naresh_1210 | Word | 0 | 03-12-2010 03:26 AM |
Exchange Server. Do I need it? | SRE | Outlook | 1 | 01-11-2010 06:36 PM |
Can I use one VERY big server for everything ? | RickH | Project | 0 | 12-15-2005 08:22 AM |