Home > Archive > Clarion > January 2005 > Need help please
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
|
|
| Dick Foster 2005-01-01, 3:55 pm |
| Using Clarion6.1 legacy
I am using two splash procedures in my application. If splash1 is open when
I call splash2, I want splash1 to close. Can someone please help me with
this code in legacy.
something like
IF splash1=open
close(splash1)
END
Thanks and happy new year and please PEACE this year.
| |
|
| Dick:
Global:
UserDefinedEventClosingSpash1 EQUATE(400h) !See Help about post
User-defined Events
!They need to start at
400h
-------------------------------
In MainFrame.
ThreadQ QUEUE,PRE(ThreadQ)
Nbr LONG
ProcName STRING(100)
END
Create a Queue in the Main Frame that contains
Thread# and Procedure Name
When a Thread Starts put the Procedure into the Thread# and
ProcedureName into the Queue.
START will give you the TRHREAD# you may need to OMIT what is
generated to capture the Thread#.
When the Splash1 Screen is closed
POST(UserDefinedEventClosingSplash1,,1) have Main Frame Remove Item
from Queue.
CASE EVENT()
OF UserDefinedEventClosingSpash1
ThreadQ.ProcName='Spash1'
GET(ThreadQ,ThreadQ.ProcName)
IF NOT ErrorCode()
DELETE(ThreadQ)
END
END
Before Splash2 is open you need to check to see if Splash1 is in
Queue.
IF it is in your Queue you need to
POST(Event:CloseWindow,,ThreadQ.Nbr) for your Spash1 Thread.
I think something like this should work. You probably need similiar
stuff for Spash2 also, since I assume you want Spash2 to close if
Spalsh1 is opened.
Jim Mumford
| |
| Dick Foster 2005-01-01, 8:55 pm |
| Jim...thanks I'll try it.....Have a happy new year.
Dick Foster
"JMumf" <jmmfrd@yahoo.com> wrote in message
news:1104603606.786922.63390@z14g2000cwz.googlegroups.com...
> Dick:
>
> Global:
> UserDefinedEventClosingSpash1 EQUATE(400h) !See Help about post
> User-defined Events
> !They need to start at
> 400h
> -------------------------------
> In MainFrame.
> ThreadQ QUEUE,PRE(ThreadQ)
> Nbr LONG
> ProcName STRING(100)
> END
>
>
> Create a Queue in the Main Frame that contains
>
> Thread# and Procedure Name
> When a Thread Starts put the Procedure into the Thread# and
> ProcedureName into the Queue.
> START will give you the TRHREAD# you may need to OMIT what is
> generated to capture the Thread#.
>
> When the Splash1 Screen is closed
> POST(UserDefinedEventClosingSplash1,,1) have Main Frame Remove Item
> from Queue.
>
> CASE EVENT()
> OF UserDefinedEventClosingSpash1
> ThreadQ.ProcName='Spash1'
> GET(ThreadQ,ThreadQ.ProcName)
> IF NOT ErrorCode()
> DELETE(ThreadQ)
> END
> END
>
> Before Splash2 is open you need to check to see if Splash1 is in
> Queue.
>
> IF it is in your Queue you need to
> POST(Event:CloseWindow,,ThreadQ.Nbr) for your Spash1 Thread.
>
> I think something like this should work. You probably need similiar
> stuff for Spash2 also, since I assume you want Spash2 to close if
> Spalsh1 is opened.
>
> Jim Mumford
>
| |
|
| Dick:
Global:
UserDefinedEventClosingSpash1 EQUATE(400h) !See Help about post
User-defined Events
!They need to start at
400h
-------------------------------
In MainFrame.
ThreadQ QUEUE,PRE(ThreadQ)
Nbr LONG
ProcName STRING(100)
END
Create a Queue in the Main Frame that contains
Thread# and Procedure Name
When a Thread Starts put the Procedure into the Thread# and
ProcedureName into the Queue.
START will give you the TRHREAD# you may need to OMIT what is
generated to capture the Thread#.
When the Splash1 Screen is closed
POST(UserDefinedEventClosingSplash1,,1) have Main Frame Remove Item
from Queue.
CASE EVENT()
OF UserDefinedEventClosingSpash1
ThreadQ.ProcName='Spash1'
GET(ThreadQ,ThreadQ.ProcName)
IF NOT ErrorCode()
DELETE(ThreadQ)
END
END
Before Splash2 is open you need to check to see if Splash1 is in
Queue.
IF it is in your Queue you need to
POST(Event:CloseWindow,,ThreadQ.Nbr) for your Spash1 Thread.
I think something like this should work. You probably need similiar
stuff for Spash2 also, since I assume you want Spash2 to close if
Spalsh1 is opened.
Jim Mumford
|
|
|
|
|