ADO Status indicator

bradyboyy88

Well-known Member
Joined
Feb 25, 2015
Messages
562
Hi,

I have a vb script on various users computers which links to an excel workbook as read only. On open this workbook creates an ado recordset and connection object. Through various tools inside the workbook the macros will connect to an access database and read or write to it and then close its connection. However, what I wanted to do was create a status indicator for them in the workbook that shows they are still connected and also in my extra tab I will be able to see all users online.

To do this without bogging down my main program that they are using, I had an idea such that I will have the vbscript open a seperate instance of excel which will basically ping the access database every 30 seconds with an update that the user is online. What I am wondering though, is if there is a way for one instance of excel to trigger a macro in another instance of excel.

Also, is there an ado connection event which is triggered if a connection is opened or closed/lost?
 

Excel Facts

Using Function Arguments with nested formulas
If writing INDEX in Func. Arguments, type MATCH(. Use the mouse to click inside MATCH in the formula bar. Dialog switches to MATCH.
I am seeing some posts using getobject to run a macro in another workbook. It seems to reference the full path which makes me think this is for executing code in a closed workbook, is this true? Also, is it running that macro in the originating instance of excel that has the getobject code in it? I am trying to get my second instance of excel to trigger the macro in the main instance of excel and run that macro in the main instance of excel as that is where all the global variables are located and such.
 
Upvote 0

Forum statistics

Threads
1,223,889
Messages
6,175,223
Members
452,620
Latest member
dsubash

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top