Hi John,

Have you looked at “$myCoolObject" in the Debugger? Does a property named 
"action" exist?

I just tried passing an object argument. The assignment in your line below 
works, provided the object passed actually exists (i.e., is at a minimum an 
empty object "{}"):

--
    C_Object($myCoolObject;$1)
    $myCoolObject:=$1
--

But your line below will fail when the property name “action" does **NOT** 
exist:

--
    If($myCoolObject.action=“Startup”)  // this will generate a syntax error.
    End If
--

When trying to retrieve a property, "OB SET" and "OB Get” work, whether or not 
the property name exists. 

But object dot notation appears to require that the property name **already 
exists** before getting or setting its value.

- Jeremy French


> On Sep 2, 2017, at 5:43 PM, John Baughman via 4D_Tech <[email protected]> 
> wrote:
> 
>       C_Object($myCoolObject;$1)
>       $myCoolObject:=$1
>       If($myCoolObject.action=“Startup”)  // this will generate a syntax 
> error.
>       End If

**********************************************************************
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[email protected]
**********************************************************************

Reply via email to