J
Joe Delphi
Hi,
I have two forms in my MS Access program. In one of the forms I
have a public variable declared in the declaration section
Form1:
Public strTest As String
Option Compare Database
-------------------------------------
In Form 2, I attempt to reference that variable like this:
Variable2 = Form1.strTest
also tried: Variable2 = Form1!strTest but that didn't work
either.
But I get an error message which says "Object required" when my
code is executing in Form 2. There is no Option Explicit setting in Form 2.
How should I reference the public variable in Form 2 so that I do
not get an error message?
JD
I have two forms in my MS Access program. In one of the forms I
have a public variable declared in the declaration section
Form1:
Public strTest As String
Option Compare Database
-------------------------------------
In Form 2, I attempt to reference that variable like this:
Variable2 = Form1.strTest
also tried: Variable2 = Form1!strTest but that didn't work
either.
But I get an error message which says "Object required" when my
code is executing in Form 2. There is no Option Explicit setting in Form 2.
How should I reference the public variable in Form 2 so that I do
not get an error message?
JD