I have the followig code in a routine, which i neeed it to
refresh data in different forms, having objFormName= to
the form name.

&objFormName..GridSignOff.RecordSource='rv_view_singOffList
VirtualSql'
&objFormName..GridSignOff.Refresh()

Everithing works well, but when I compile the application,
I get a message stating the the form name contained in the
variable objFormName is not an object.

What i am doing wrong here?
Can anybody help before i perform a "MACRO SUBSTITUTION"
to my monitor?!

Re: macro substitution by mappell917

mappell917
Mon Sep 08 12:22:39 CDT 2003

Hello - first of all, it does not seem like you should need macro substitution
in your routine. Why not just set a variable or property to the form object.
Example:

loForm = thisform

loForm.GridSignOff.RecordSource = etc etc

But, if you insist on macro substitution, try setting objFormName to
"thisform.GridSignOff.RecordSource"

But - you should not need macro substitution at all.

Regards


>I have the followig code in a routine, which i neeed it to
>refresh data in different forms, having objFormName= to
>the form name.
>
>&objFormName..GridSignOff.RecordSource='rv_view_singOffList
>VirtualSql'
>&objFormName..GridSignOff.Refresh()
>
>Everithing works well, but when I compile the application,
>I get a message stating the the form name contained in the
>variable objFormName is not an object.
>
>What i am doing wrong here?
>Can anybody help before i perform a "MACRO SUBSTITUTION"
>to my monitor?!
>
>
>
>
>


Mike