INT-trigger $instancehandle vs. $instancename() resp. "->" vs. "activate"

Author: (istiller)

Ist this a bug or a feature :-) Say, I call a global proc from INIT-trigger. In this global proc, I want to callback the instance GP_DO_INIT   ;a) do it by handle   $instancehandle->"CB_ME"()   ;   ;b) do it by activate   activate $instancename."CB_ME"() END a) is doing what I want BUT b) I got an error -58  "Component not found" Further investigation reveald that $instancename is valid but the instance is at this point not in the instance pool. Why are the different behavior? Is this a bug or a feature :-) Ingo

1 Comment

  1. Hi Ingo, I did a quick test here and my test results are a little bit different: a) is returning the error -84 (No Handle or empty Handle specified) b) is returning the error -58 as well Not sure what I'm doing wrong here, but I don't see a different behavior here. Confused And when you say INIT-trigger then you probably mean INIT operation, correct? Which Uniface version did you use? I've used version 8 and 9 (all the versions I could find). But I think that it's normal that you cannot call an operation from the INIT operation using $instancename or $instancehandle. The instance is only really (completely) available after the INIT operation is finished. At least that's what I've been told. Hope this helps. Daniel

    Author: diseli (