Global Variables in Add-Ins

D

Doug B.

I have put together an add-in which has several global variables used
between the different forms of the add-ins.

The variables are declared in a module which I call basDeclarations.
The variables are dimmed as:

Public gstrUsrName as string

The problem arises only when the application is launched as an Add-In.
A message appears which states "..can't find the wizard, or the wizard
has not been installed, or there is a syntax error in the Declarations
section of a Visual Basic module."

The addition of the global variables is the only thing which changed
from the last iteration of this add-in. Is there a limitation on using
global variables from Access Add-Ins?

Any help will be appreciated. Thanks in advance.

-Doug
Best wishes,

Doug B.
 
J

Jeff Conrad

in message:
I have put together an add-in which has several global variables used
between the different forms of the add-ins.

The variables are declared in a module which I call basDeclarations.
The variables are dimmed as:

Public gstrUsrName as string

The problem arises only when the application is launched as an Add-In.
A message appears which states "..can't find the wizard, or the wizard
has not been installed, or there is a syntax error in the Declarations
section of a Visual Basic module."

The addition of the global variables is the only thing which changed
from the last iteration of this add-in. Is there a limitation on using
global variables from Access Add-Ins?

Any help will be appreciated. Thanks in advance.

Hi Doug,

I cannot seem to reproduce this problem.

I just created a quick test add-in and used the same declaration
as your code. I have the add-in open a form, assign a string to
that global variable and pop up a message box with that global
variable. Everything worked fine.

Can you give a few more specifics on this issue?
Access version?
Operating system version?
Did you set up a USYSRegInfo table?
Are you launching the add-in from the add-in menu?
Did you install the add-in through the Add-In Manager?
Can you provide a little more code where the error occurs?
etc.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top