Run code

  • Thread starter Thread starter Chris
  • Start date Start date
C

Chris

Hi,

I want to run a special process every morning from Monday
to Friday is it possible to do it with VBA

My process is a VBA methode

Thanks
 
Well... unless someone can come up with a better way...

2 or 3 ways to do it :

1. Use Visual Basic (not access) and compile a basic exe with the method
in it. Chances are all the code will work pretty much unmodified. Then
just use windows scheduler to run it mon-fri.

2. Create a windows script file (.vbs). This will runn pretty much like
an ASP page (also vb script) w/o IIS or like a standalone VBA file
(which is what it is!). I don't recall if anything extra was required
other than the base windows install, but it should be available free
from MS if it is. Then just schedule it like normal in windows
scheduler again :

http://msdn.microsoft.com/library/d...n-us/script56/html/wsoriWindowsScriptHost.asp

I think most of the samples there are in JScript (.js), but there should
be enough info.

To test it, just make a "test.vbs" file (rename a .txt file?), and put '
msgbox "test wsh"' in it. Double clicking on it should pop up a message
box.

HTH,
Andrew Backer
 
Back
Top