If you don't call STDCall and then make a call to the function, the function 
will fail.

STDCall is just a declaration in the rbase environment to set a reference 
(accesss) to the function.  Notably, ANY win32 API function does NOT have to be 
loaded with a call to DLLoad because the API functions are already loaded as a 
part of Windows.

>
Does it hurt anything to call STDCALL more than once in a session?
>
Likely no, but very bad practice.  If you would change anything in the 
subsequent call, you "could" muck up the reference.

>
Is there a check function that I need to run to see if it has already been 
called or not?
>

No.

Further, the function declaration in StdCall, the FunctionName is case 
sensitive in the declaration, so if you are using an API function, refer to 
http://msdn2.microsoft.com/en-us/library/default.aspx for the proper casing. 
Everything you need to know about windows is there.




-----Original Message-----
From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf Of MikeB
Posted At: Wednesday, March 19, 2008 11:49 AM
Posted To: RB7-L
Conversation: [RBASE-L] - Re: MDI form and waiting
Subject: [RBASE-L] - Re: MDI form and waiting


Missed a dot on iMax in the While:

while vVariableInForm1 = 'False' or iTick <> .iMAX then

----- Original Message -----
From: "MikeB" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Wednesday, March 19, 2008 12:46 PM
Subject: Re: [RBASE-L] - MDI form and waiting


> {
> Declare the following ONCE
> somewhere in the session (On before startEEP is ok)
> }
>
> STDCALL void 'Sleep' (integer)
> STDCALL function 'GetTickCount' () : integer
>
>
> {Then your Form code:}
>
> set var iTick INTEGER = (dlcall('kernel32','getTickcount'))
>
> set var iMAX int = (.iTick + 15000)  -- Max time in ms you want to wait if
> you want a limit
>
> while vVariableInForm1 = 'False' or iTick <> iMAX then
>
> ...  --some code to check vVariableInForm1's value.
>  set var iTick INTEGER = (dlcall('kernel32','getTickcount'))
>  ProcessMessage
>  SET VAR vret = (dlcall('kernel32','sleep', 500)) -- 500ms
> endwhile
>
>
> ----- Original Message -----
> From: "Charles Parks" <[EMAIL PROTECTED]>
> To: "RBASE-L Mailing List" <[email protected]>
> Sent: Wednesday, March 19, 2008 12:15 PM
> Subject: [RBASE-L] - MDI form and waiting
>
>
> If a variable value is being set in a different form opened with a MDI option
> is there a way to wait until that value has been set been set before calling
> the next line of code in the calling form?
>
> The following works in tracing but locks up in running mode.
>
> set var vVariableInForm1 text = 'False'
>
> EDIT USING Form1 MDI AS Form1  --vVariableInForm1 will be set to true in this
> form and the form will be closed with CloseWindow
>
> while vVariableInForm1 = 'False' then
> ...  --some code to check vVariableInForm1's value.
> endwhile
>
> ...  --Continue with calling form's code.
>
> Is there a pause timer shorter than 1?
>
>


Reply via email to