Visual Basic editor window

  • Thread starter Thread starter JoD
  • Start date Start date
J

JoD

When I open my Access2003 database (in Access2007), the Visual Basic editor
window also opens. How do I prevent this from opening. The users don't need
to see the code.

I have an autoexec macro that opens the main form. The following is the macro:
Echo (Echo On: No)
Hourglass (Hourglass On: Yes)
SelectObject(Module:Sharedmodule containing function) - otherwise the
RunCode step did not work
RunCode(function in Sharedmodule)
OpenForm(MainForm,View:Normal, DataMode:Edit, WindowMode:Normal)
Close(Sharedmodule containing function)
 
JoD said:
When I open my Access2003 database (in Access2007), the Visual Basic
editor
window also opens. How do I prevent this from opening. The users don't
need
to see the code.

I have an autoexec macro that opens the main form. The following is the
macro:
Echo (Echo On: No)
Hourglass (Hourglass On: Yes)
SelectObject(Module:Sharedmodule containing function) - otherwise the
RunCode step did not work
RunCode(function in Sharedmodule)
OpenForm(MainForm,View:Normal, DataMode:Edit, WindowMode:Normal)
Close(Sharedmodule containing function)


It seems to me that it's your SelectObject action that is displaying the VB
window. I don't see why you would need to select the module at all. The
RunCode action doesn't normally require that the function to be executed, or
the module that contains it, be selected or displayed. What happens if you
just delete the SelectObject action and the Close action from the macro?
 
JoD said:
When I open my Access2003 database (in Access2007), the Visual Basic
editor
window also opens. How do I prevent this from opening. The users don't
need
to see the code.

I have an autoexec macro that opens the main form. The following is the
macro:
Echo (Echo On: No)
Hourglass (Hourglass On: Yes)
SelectObject(Module:Sharedmodule containing function) - otherwise the
RunCode step did not work
RunCode(function in Sharedmodule)
OpenForm(MainForm,View:Normal, DataMode:Edit, WindowMode:Normal)
Close(Sharedmodule containing function)

In your macro command SelectObject, set 'In Database Window' to Yes.
 
JoD said:
When I open my Access2003 database (in Access2007), the Visual Basic
editor
window also opens. How do I prevent this from opening. The users don't
need
to see the code.

I have an autoexec macro that opens the main form. The following is the
macro:
Echo (Echo On: No)
Hourglass (Hourglass On: Yes)
SelectObject(Module:Sharedmodule containing function) - otherwise the
RunCode step did not work
RunCode(function in Sharedmodule)
OpenForm(MainForm,View:Normal, DataMode:Edit, WindowMode:Normal)
Close(Sharedmodule containing function)

In your macro command SelectObject, set 'In Database Window' to Yes.
 
Removing the SelectObject and Close does not solve the issue of the Visual
Basic editor window from opening, unfortunately.
 
OK, now I am truly baffled. This time I removed both the SelectObject and the
Close actions, the Visual Basic editor window no longer opens and the reason
that I had inserted those in the macro, because the function did not seem to
run with them, no longer occurs.
 
Back
Top