Thank you Eric and Richard,

I've decided on the Try/Catch with an attempt to handle it again, just in
case this is just a timing issue.

When the code is implemented, the error will hopefully be swallowed, and the
support staff will be able to continue their day.

Tracy

-----Original Message-----
From: ProfoxTech [mailto:[email protected]] On Behalf Of Richard
Kaye
Sent: Tuesday, June 23, 2020 4:28 PM
To: [email protected]
Subject: RE: SetAll throws Variable Not Found

Wrap the whole thing in a TRY..CATCH and see what the exception object can
tell you.

--

rk

-----Original Message-----
From: ProfoxTech <[email protected]> On Behalf Of Eric Selje
Sent: Tuesday, June 23, 2020 2:16 PM
To: [email protected]
Subject: Re: SetAll throws Variable Not Found

Maybe iterate through the objects rather than use SetAll and find the
trouble child?

E


On Tue, Jun 23, 2020 at 12:01 PM Tracy Pearson <[email protected]>
wrote:

> Hello everyone,
>
> This code has worked for years, now sadly it is failing intermittently.
> It's
> in an internal application.
> I think the error is invalid or the line number and what method the 
> error occurs in is invalid.
>
> In a CommandGroup class, the INIT method calls the following 
> SetChildColor
> method:
>     * Set the forecolor property
>     THIS.SETALL("ForeColor", ;
>           EVALUATE( LEFT( RGBSCHEME(1,2), ;
>           AT(',', RGBSCHEME(1,2), 3) -1)+')'), "CommandButton")
>
>     THIS.SETALL("DisabledForeColor", ;
>           EVALUATE( LEFT( RGBSCHEME(1,10), ;
>           AT(",", RGBSCHEME(1,10), 3)-1)+")"), "CommandButton")
>
> Line four is throwing the error Variable is not found.
>
> To determine if it was odd timing related to the EVALUATE function we 
> changed the code to:
>     * Set the forecolor property
>     LOCAL enabledColor, disabledColor
>     enabledColor = EVALUATE( LEFT( RGBSCHEME(1,2), AT(',', 
> RGBSCHEME(1,2),
> 3) -1)+')')
>     disabledColor = EVALUATE( LEFT( RGBSCHEME(1,10),  AT(",", 
> RGBSCHEME(1,10), 3)-1)+")")
>
>     THIS.SETALL("ForeColor", enabledColor, "CommandButton")
>
>     THIS.SETALL("DisabledForeColor", disabledColor, "CommandButton")
>
> We now get the error on line 6.
>
> The stack shows the form is called, the commandgroup.init is running 
> and calls this method.
>
> I'm looking for some additional ideas to find this intermittent problem.
>
> Thank you,
> Tracy
>
>
>
[excessive quoting removed by server]

_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: https://mail.leafe.com/mailman/listinfo/profox
OT-free version of this list: https://mail.leafe.com/mailman/listinfo/profoxtech
Searchable Archive: https://leafe.com/archives
This message: 
https://leafe.com/archives/byMID/[email protected]
** All postings, unless explicitly stated otherwise, are the opinions of the 
author, and do not constitute legal or medical advice. This statement is added 
to the messages for those lawyers who are too stupid to see the obvious.

Reply via email to