Access general functions not working

  • Thread starter Thread starter Jimbob
  • Start date Start date
J

Jimbob

Our company just put SP4 on our Windows 2000 machines. My
Macro RunCode commands like: shell("C:\WINNT\system32
\calc.exe") just a simple example, come up with an error
that the Function Shell is not found. I also have the
problem when I use the Environ$("Username") function in a
query.
When I create a new Function called DOS1 in a module and I
only put shell("C:\WINNT\system32\calc.exe") in the new
function, then the DOS1 function works and it recognizes
shell. Anyone else experiencing this?
 
Our company just put SP4 on our Windows 2000 machines. My
Macro RunCode commands like: shell("C:\WINNT\system32
\calc.exe") just a simple example, come up with an error
that the Function Shell is not found. I also have the
problem when I use the Environ$("Username") function in a
query.
When I create a new Function called DOS1 in a module and I
only put shell("C:\WINNT\system32\calc.exe") in the new
function, then the DOS1 function works and it recognizes
shell. Anyone else experiencing this?
This appears to be the very common References bug. Open any
module in design view, or open the VBA editor by typing
Ctrl-G. Select Tools... References from the menu. One of the
..DLL files required by Access will probably be marked
MISSING. Uncheck it, recheck it, close and open Access.

If none are MISSING, check any reference; close and open
Access; then uncheck it again. This will force Access to
relink the libraries.
 
This is likely a sandbox mode issue. When Windows 2000 was upgraded to SP4, you automatically
received an update of JET 4.0 (perhaps SP6, but I'm not positive). Check out the following KB
article:

How to configure Jet 4.0 to prevent unsafe functions from running in Access 2003
http://support.microsoft.com/?kbid=294698

or

How to configure Jet 4.0 to prevent unsafe functions from running in Access 2000 and Access 2002
http://support.microsoft.com/?id=239482


Tom
____________________________________


Our company just put SP4 on our Windows 2000 machines. My
Macro RunCode commands like: shell("C:\WINNT\system32
\calc.exe") just a simple example, come up with an error
that the Function Shell is not found. I also have the
problem when I use the Environ$("Username") function in a
query.

When I create a new Function called DOS1 in a module and I
only put shell("C:\WINNT\system32\calc.exe") in the new
function, then the DOS1 function works and it recognizes
shell. Anyone else experiencing this?
 
After going back and reading some of the older postings I
found my answer. SP4 moves the SandBoxmode setting up to
a 3 instead of the old default of 2. I changed the
registry value for Sandboxmode to 2 and then my macros
worked again.
 
Back
Top