ActiveX Control License?

  • Thread starter Thread starter gdavi
  • Start date Start date
G

gdavi

I am trying to troubleshoot a form which prompts users for report
parameters. It was working just fine in Access 2000 and 2002, but since
we've switched to 2003 we're getting error messages with it.

This unbound form has an OK button control which is supposed to set the
form's visible property to no, then the report opens using the data typed
into an unbound field on the form to populate the report. It uses the "Set
Value" function to set the visible property to no. Since the upgrade to 2003
though, the button returns the following message:

"You entered an expression that has an invalid reference to the property
visible"

I tried rebuilding the macro using the syntax
[Forms]![frmReportCriteria].[Visible] for the Set Value function. This
results in the following error message:

"You don't have the license required to use this ActiveX control"

Any ideas out there? The Microsoft KB didn't seem to have any answers.
Thanks...
Gary
 
Gary:

You don't use SetValue to set a form's visible property to false. In fact
it is a waste of a macro to do so, when you can do this using one line of
VBA code. In the On Click event of the OK button, set it to use an event
procedure. Then simply add code like this:

Me.Visible = False
'Follow with code to open your other form and set a value into a text box.

Now, if I've mis-understood entirely your issue in that you are using VBA
(and calling it a macro), and you are receiving an error, then you may want
to check the references that the database has set because it is likely that
there is a missing reference causing the VBA in the database to fail to
compile properly. To do this open a general module and in the VB Editor
from the Tools Menu, choose Refrences and see what might be listed as
"Missing" and try resolve that missing reference.
 
Thanks Steve...
I used your code and the button now acts as it should. I was using a macro
as the database in question was designed quite awhile ago. All's well now.
Gary


SA said:
Gary:

You don't use SetValue to set a form's visible property to false. In fact
it is a waste of a macro to do so, when you can do this using one line of
VBA code. In the On Click event of the OK button, set it to use an event
procedure. Then simply add code like this:

Me.Visible = False
'Follow with code to open your other form and set a value into a text box.

Now, if I've mis-understood entirely your issue in that you are using VBA
(and calling it a macro), and you are receiving an error, then you may want
to check the references that the database has set because it is likely that
there is a missing reference causing the VBA in the database to fail to
compile properly. To do this open a general module and in the VB Editor
from the Tools Menu, choose Refrences and see what might be listed as
"Missing" and try resolve that missing reference.
--
Steve Arbaugh
ACG Soft
http://ourworld.compuserve.com/homepages/attac-cg

gdavi said:
I am trying to troubleshoot a form which prompts users for report
parameters. It was working just fine in Access 2000 and 2002, but since
we've switched to 2003 we're getting error messages with it.

This unbound form has an OK button control which is supposed to set the
form's visible property to no, then the report opens using the data typed
into an unbound field on the form to populate the report. It uses the "Set
Value" function to set the visible property to no. Since the upgrade to 2003
though, the button returns the following message:

"You entered an expression that has an invalid reference to the property
visible"

I tried rebuilding the macro using the syntax
[Forms]![frmReportCriteria].[Visible] for the Set Value function. This
results in the following error message:

"You don't have the license required to use this ActiveX control"

Any ideas out there? The Microsoft KB didn't seem to have any answers.
Thanks...
Gary
 
Back
Top