Waitkey question
George Simon
GSimon at americanriverintl.com
Fri Dec 29 12:18:58 PST 2006
If you had the waitkey, you would hang at that line until some keystroke was entered. Why are you are pushing "Q"? That would defeat the purpose of the waitkey, I think.
I don't see an "end" after the @entsel code, so it would fall through to the @keyQ code and blow past the waitkey because of the pushed key.
George Simon Sr. Programmer
Information Technologies
American River International
-----Original Message-----
From: Don Coleman [mailto:dcoleman at dgcreact.com]
Sent: Friday, December 29, 2006 3:10 PM
To: George Simon; 'filePro Mailing List'
Subject: RE: Waitkey question
> -----Original Message-----
> From: George Simon [mailto:GSimon at americanriverintl.com]
> Sent: Friday, December 29, 2006 2:55 PM
> To: Don Coleman; filePro Mailing List
> Subject: RE: Waitkey question
>
> 28 ------- - - - - - - - -
> @entsel◄ If:
> Then:
> 29 ------- - - - - - - - -
> ◄ If:
> Then: wk=waitkey
> 30 ------- - - - - - - - -
> ◄ If: @sk="save"
> Then: exit
> 31 ------- - - - - - - - -
> ◄ If:
> Then: goto @entsel
>
> This code exits for me every time I hit the <esc> key.
>
>
George:
You're right, the combination of waitkey and @SK does exit. However, in my scenario every 15 seconds the cursor goes to the end of the SHOW statement and awaits a user response. So my screen would require user acknowledgement every 15 seconds. Not sure why this is happening. Removing the waitkey & @SK eliminates this problem.
Don Coleman
Donald G. Coleman, Consultant
402 Andrew Circle
Indiana, PA 15701
dcoleman at dgcreact.com
(724) 349-6302
>
>
> -----Original Message-----
> From: Don Coleman [mailto:dcoleman at dgcreact.com]
> Sent: Friday, December 29, 2006 2:49 PM
> To: George Simon; 'filePro Mailing List'
> Subject: RE: Waitkey question
>
>
>
>
> > -----Original Message-----
> > From: George Simon [mailto:GSimon at americanriverintl.com]
> > Sent: Friday, December 29, 2006 2:36 PM
> > To: Don Coleman; filePro Mailing List
> > Subject: RE: Waitkey question
> >
> > Instead of AD="save", try @sk="save"
> >
> George:
>
> I actually tried @SK first, it never exits. Replaced line 6 with:
> @SK eq "SAVE"
> exit
>
> Don Coleman
> Donald G. Coleman, Consultant
> 402 Andrew Circle
> Indiana, PA 15701
> dcoleman at dgcreact.com
> (724) 349-6302
> >
> > Please note that my new email address is
> > gsimon at americanriverintl.com
> > Please start using that address in all correspondence immediately.
> > Thank you!
> >
> > George Simon Sr. Programmer
> > Information Technologies
> > American River International
> >
> >
> > -----Original Message-----
> > From: filepro-list-bounces+george=worldest.com at lists.celestial.com
> > [mailto:filepro-list-bounces+george=worldest.com at lists.celestial.com] On
> > Behalf Of Don Coleman
> > Sent: Friday, December 29, 2006 2:18 PM
> > To: 'filePro Mailing List'
> > Subject: Waitkey question
> >
> > I wrote the following table to monitor another *clerk process which
> > calls
> > various forms and prints them. It alerts the user when the print queue
> > count gets too high. That portion works fine. My final step was to add
> > lines 5-6 in order to allow the user a graceful exit method and avoid
> > closing the window via the "X" close method in Windows. If I un-comment
> > lines 5-6 and the user presses the ESCAPE key the application does not
> > exit
> > as desired but it does "hang" on line #2, awaiting the user to press the
> > ENTER key. What do I have wrong in order to press the ESCAPE key (or
> > any
> > other key) to allow for a graceful exit? Thank you and Happy New Year!
> >
> >
> >
> >
> > Dec 29, 2006 13:58 File Name: CONTROL Page
> > 1
> > Processing: Auto_Print_Queue
> >
> > 1 ------- - - - - - - - - - - - - - - -
> > -
> > If:
> > Then: end
> > 2 ------- - - - - - - - - - - - - - - -
> > -
> > @ENTSEL If:
> > Then: SHOW "Press \r<ESCAPE>\r to exit the Auto Print Queue
> > Monitor";push
> > key "Q"
> > 3 ------- - - - - - - - - - - - - - - -
> > -
> > @KEYQ If:
> > Then: AA(2,ALLUP,g)="Y "
> > 4 ------- - - - - - - - - - - - - - - -
> > -
> > start If:
> > Then: lookup qs1 k=AA i=F -ng
> > 5 ------- - - - - - - - - - - - - - - -
> > -
> > If:
> > Then: 'AD(4,*)=waitkey
> > 6 ------- - - - - - - - - - - - - - - -
> > -
> > If: 'AD eq "SAVE"
> > Then: 'exit
> > 7 ------- - - - - - - - - - - - - - - -
> > -
> > If: AB ge "30"
> > Then: beep;msgbox "\r ***** WARNING WARNING WARNING *****
> > \r\n\r
> > # of labels in the print queue is escalating \r"
> > 8 ------- - - - - - - - - - - - - - - -
> > -
> > If:
> > Then: AB="0"
> > 9 ------- - - - - - - - - - - - - - - -
> > -
> > more If: not qs1
> > Then: AC(47,*)=""{AB<"Labels in Auto Print Queue as
> > of"<@TM;display;sleep
> > "15000";goto start
> > 10 ------- - - - - - - - - - - - - - - -
> > -
> > If: qs1(76) eq "Y"
> > Then: AC=""{AB<"Labels in Auto Print Queue as
> > of"<@TM;display;sleep
> > "1500
> > 0";goto start
> > 11 ------- - - - - - - - - - - - - - - -
> > -
> > If: qs1(112) eq "Y" and qs1(76) ne "Y"
> > Then: AB(5,.0,g)=(AB+"1");getnext qs1;goto more
> > 12 ------- - - - - - - - - - - - - - - -
> > -
> > If:
> > Then: getnext qs1;goto more
> >
> > Don Coleman
> > Donald G. Coleman, Consultant
> > 402 Andrew Circle
> > Indiana, PA 15701
> > dcoleman at dgcreact.com
> > (724) 349-6302
> >
> >
> >
> > _______________________________________________
> > Filepro-list mailing list
> > Filepro-list at lists.celestial.com
> > http://mailman.celestial.com/mailman/listinfo/filepro-list
>
>
More information about the Filepro-list
mailing list