[AccessD] Problem adding a param. to a function

John Clark John.Clark at niagaracounty.com
Thu May 6 14:04:49 CDT 2004


OK...this is probably something boneheaded and simple, but I haven't
posted any problems in a while, and my head feels like it is going to
explode from behind my eye sockets, so please bare with me...
 
I have been asked to do some alterations/additions to a program that I
wrote, a little over a year ago. What I am working on now is the simple
addition of a new report. I usually leave some 'reserved' buttons on my
Reports Menu because they always want more reports, so the buttons are
already there.
 
On my reports menu, I have hidden fields to accomodate a couple of the
different reports. These fields become visible, depending on the report
chosen--I have one that uses 'Start Date' and an 'End Date' fields, and
another that uses a drop-down to choose an employee. These also each
have a cancel button, and a proceed button. After you cancel or proceed,
the main buttons, which were disabled, when one was chosen, are
re-enabled, and the used fields become invisible again.
 
This report that I have added is also dependent on a starting and
ending date, so I used the same function to do the button magic (i.e.
disappear, reappear, setfocus, enable, etc.). However I needed an extra
IF statement to decipher which of two buttons was chosen. So I added the
if statement and added a parameter to go with it:
 
Function SeeDateInfo(Mode As Boolean)
 
has become
 
Function SeeDateInfo(Mode As Boolean, Button As Integer)
 
but when I change the function call to add another parameter, the help
tip comes up correctly--it tells me what it is looking for--but I get an
error:  Compile Error ... Expected: =
 
What in the hey am I doing wrong?!
 
Thanks for the help...now and in the past!
 
I gotta fly now to get my daughter's tooth yanked...arrrrghtt!!!
 
btw...A97
 
John W Clark



More information about the AccessD mailing list