Re: [U2] Press any key to continue...
IMHO I find the mixed use of INPUT statements with some not requiring an keystroke while most requiring the to be incredibly distracting. I've long heard the argument that saving the user the single pathetic keystroke has value but not when things go wrong. In the big picture it's a function of who is programming whom. While it can be argued that some Y/N questions don't require the , it creates an inconsistent interface, removing the opportunity should they press "Y" when they wanted "N". I've seen 3, 4 and even date answers of the form INPUT ANS,8: where the is implied upon the entry of the 8th character. Then the answer could accidentally apply to the next question and then more inconsistency ensues. Just an opinion, Mark Johnson - Original Message - From: "Brutzman, Bill" <[EMAIL PROTECTED]> To: Sent: Wednesday, April 30, 2008 10:50 AM Subject: RE: [U2] Press any key to continue... > On a lot of screens here , I force end-users to type 'x' to exit (per the > following code) so that they do not bypass an error message screen. > > I also use square brackets [#] on a single-character prompts and triangular > brackets on multi-character prompts <#> so that end-users know what to > expect. > > --Bill > > * > Error.Prompt: > > crt @(-1) > > crt @(10,10) : ' Descriptive Error Message ' : > crt @(10,11) : ' [X] : > > input Ans.Error, 1 > Ans.Error = upcase(Ans.Error) > > begin case > case Ans.Error = 'X' ; null > case 1; call *BEEP.BEEP.AND.SLEEP.R0 ; go > Error.Prompt > end case > > return to Main.Screen > > *- > --- > u2-users mailing list > u2-users@listserver.u2ug.org > To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue...
Oops, it's Unidata.not sure what Universe isbut I originally wrote the word processor in PICK and moved it to Unidata. I can't remember what the pick equivalent was, but like it was something like KEYFNS or something like that Basically it returns the value of every key pressed when in a loop, exactly what you need for word processing or ANYKEY stuff -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Eric Armstrong Sent: Thursday, May 01, 2008 09:05 To: u2-users@listserver.u2ug.org Subject: RE: [U2] Press any key to continue... Allen, I don't see the IN() form of input in my documention for Universe 10.1.18. Eric -Original Message- From: Allen E. Elwood [mailto:[EMAIL PROTECTED] Sent: Wednesday, April 30, 2008 2:35 PM To: u2-users@listserver.u2ug.org Subject: RE: [U2] Press any key to continue... I think you could just get away using the IN() form of input. CH.IN = SEQ(IN()) This is from the word processor I wrote where it returns the numeric value of any key pressed *including* the space bar. You wouldn't need to evaluate the response for your purpose though hth Allen -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Marc Harbeson Sent: Wednesday, April 30, 2008 13:50 To: u2-users@listserver.u2ug.org Subject: RE: [U2] Press any key to continue... In this case, simply re-labeling the "Enter" key as "Any" would be the best way to proceed -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Colin Alfke Sent: Wednesday, April 30, 2008 4:13 PM To: u2-users@listserver.u2ug.org Subject: RE: [U2] Press any key to continue... We had one user (a lawyer - go figure) complain, quite vigorously, that the key wouldn't be accepted as "ANY" key. Colin Alfke Calgary, Canada -Original Message- From: Steve Ferries Hi All, We were coding a standard INPUT ANS after asking a user to "Press any key to continue...". We noticed that the program would not accept a Space Bar as a valid key; it only moves the cursor to the right. --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ LOBEL FINANCIAL PRIVACY NOTICE: This communication may contain confidential company information that is protected by federal law. Federal regulations prohibit the disclosure (or re-disclosure) of confidential information without the written consent of the person(s) to whom it pertains. Additionally, the views or opinions presented in this email are solely those of the author and do not necessarily represent those of the company. --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue...
That's and old Pick Basic command, it's been replaced by KEYIN() in Universe. Jerry Banker Senior Programmer Analyst IBM Certified Solutions Expert -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Eric Armstrong Sent: Thursday, May 01, 2008 11:05 AM To: u2-users@listserver.u2ug.org Subject: RE: [U2] Press any key to continue... Allen, I don't see the IN() form of input in my documention for Universe 10.1.18. Eric -Original Message- From: Allen E. Elwood [mailto:[EMAIL PROTECTED] Sent: Wednesday, April 30, 2008 2:35 PM To: u2-users@listserver.u2ug.org Subject: RE: [U2] Press any key to continue... I think you could just get away using the IN() form of input. CH.IN = SEQ(IN()) This is from the word processor I wrote where it returns the numeric value of any key pressed *including* the space bar. You wouldn't need to evaluate the response for your purpose though hth Allen -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Marc Harbeson Sent: Wednesday, April 30, 2008 13:50 To: u2-users@listserver.u2ug.org Subject: RE: [U2] Press any key to continue... In this case, simply re-labeling the "Enter" key as "Any" would be the best way to proceed -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Colin Alfke Sent: Wednesday, April 30, 2008 4:13 PM To: u2-users@listserver.u2ug.org Subject: RE: [U2] Press any key to continue... We had one user (a lawyer - go figure) complain, quite vigorously, that the key wouldn't be accepted as "ANY" key. Colin Alfke Calgary, Canada -Original Message- From: Steve Ferries Hi All, We were coding a standard INPUT ANS after asking a user to "Press any key to continue...". We noticed that the program would not accept a Space Bar as a valid key; it only moves the cursor to the right. --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ LOBEL FINANCIAL PRIVACY NOTICE: This communication may contain confidential company information that is protected by federal law. Federal regulations prohibit the disclosure (or re-disclosure) of confidential information without the written consent of the person(s) to whom it pertains. Additionally, the views or opinions presented in this email are solely those of the author and do not necessarily represent those of the company. --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue...
Allen, I don't see the IN() form of input in my documention for Universe 10.1.18. Eric -Original Message- From: Allen E. Elwood [mailto:[EMAIL PROTECTED] Sent: Wednesday, April 30, 2008 2:35 PM To: u2-users@listserver.u2ug.org Subject: RE: [U2] Press any key to continue... I think you could just get away using the IN() form of input. CH.IN = SEQ(IN()) This is from the word processor I wrote where it returns the numeric value of any key pressed *including* the space bar. You wouldn't need to evaluate the response for your purpose though hth Allen -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Marc Harbeson Sent: Wednesday, April 30, 2008 13:50 To: u2-users@listserver.u2ug.org Subject: RE: [U2] Press any key to continue... In this case, simply re-labeling the "Enter" key as "Any" would be the best way to proceed -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Colin Alfke Sent: Wednesday, April 30, 2008 4:13 PM To: u2-users@listserver.u2ug.org Subject: RE: [U2] Press any key to continue... We had one user (a lawyer - go figure) complain, quite vigorously, that the key wouldn't be accepted as "ANY" key. Colin Alfke Calgary, Canada -Original Message- From: Steve Ferries Hi All, We were coding a standard INPUT ANS after asking a user to "Press any key to continue...". We noticed that the program would not accept a Space Bar as a valid key; it only moves the cursor to the right. --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ LOBEL FINANCIAL PRIVACY NOTICE: This communication may contain confidential company information that is protected by federal law. Federal regulations prohibit the disclosure (or re-disclosure) of confidential information without the written consent of the person(s) to whom it pertains. Additionally, the views or opinions presented in this email are solely those of the author and do not necessarily represent those of the company. --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue...
I think you could just get away using the IN() form of input. CH.IN = SEQ(IN()) This is from the word processor I wrote where it returns the numeric value of any key pressed *including* the space bar. You wouldn't need to evaluate the response for your purpose though hth Allen -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Marc Harbeson Sent: Wednesday, April 30, 2008 13:50 To: u2-users@listserver.u2ug.org Subject: RE: [U2] Press any key to continue... In this case, simply re-labeling the "Enter" key as "Any" would be the best way to proceed -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Colin Alfke Sent: Wednesday, April 30, 2008 4:13 PM To: u2-users@listserver.u2ug.org Subject: RE: [U2] Press any key to continue... We had one user (a lawyer - go figure) complain, quite vigorously, that the key wouldn't be accepted as "ANY" key. Colin Alfke Calgary, Canada -Original Message- From: Steve Ferries Hi All, We were coding a standard INPUT ANS after asking a user to "Press any key to continue...". We noticed that the program would not accept a Space Bar as a valid key; it only moves the cursor to the right. --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue...
Ah. a new product line MS Keyboard, esquire -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Marc Harbeson Sent: Wednesday, April 30, 2008 3:50 PM To: u2-users@listserver.u2ug.org Subject: RE: [U2] Press any key to continue... In this case, simply re-labeling the "Enter" key as "Any" would be the best way to proceed -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Colin Alfke Sent: Wednesday, April 30, 2008 4:13 PM To: u2-users@listserver.u2ug.org Subject: RE: [U2] Press any key to continue... We had one user (a lawyer - go figure) complain, quite vigorously, that the key wouldn't be accepted as "ANY" key. Colin Alfke Calgary, Canada -Original Message- From: Steve Ferries Hi All, We were coding a standard INPUT ANS after asking a user to "Press any key to continue...". We noticed that the program would not accept a Space Bar as a valid key; it only moves the cursor to the right. --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue...
In this case, simply re-labeling the "Enter" key as "Any" would be the best way to proceed -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Colin Alfke Sent: Wednesday, April 30, 2008 4:13 PM To: u2-users@listserver.u2ug.org Subject: RE: [U2] Press any key to continue... We had one user (a lawyer - go figure) complain, quite vigorously, that the key wouldn't be accepted as "ANY" key. Colin Alfke Calgary, Canada -Original Message- From: Steve Ferries Hi All, We were coding a standard INPUT ANS after asking a user to "Press any key to continue...". We noticed that the program would not accept a Space Bar as a valid key; it only moves the cursor to the right. --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue...
We had one user (a lawyer - go figure) complain, quite vigorously, that the key wouldn't be accepted as "ANY" key. Colin Alfke Calgary, Canada -Original Message- From: Steve Ferries Hi All, We were coding a standard INPUT ANS after asking a user to "Press any key to continue...". We noticed that the program would not accept a Space Bar as a valid key; it only moves the cursor to the right. --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue...
You might want to look at CINPUT.SUB.B in the APP.PROGS file in the UV account. Roy -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Baker Hughes Sent: Wednesday, April 30, 2008 10:53 AM To: 'u2-users@listserver.u2ug.org' Subject: RE: [U2] Press any key to continue... If I could extend the question just a little ... would anyone like to share their Standard.Input.Sub that they call from all their input screens. Its always illuminating to see how others do it. -Baker --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue...
You can also try ANS = KEYIN() -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ferries Sent: Tuesday, April 29, 2008 2:46 PM To: u2-users@listserver.u2ug.org Subject: [U2] Press any key to continue... Hi All, We were coding a standard INPUT ANS after asking a user to "Press any key to continue...". We noticed that the program would not accept a Space Bar as a valid key; it only moves the cursor to the right. However, the Press any key to continue... message from UniVerse accepts the Space Bar as a valid key. Can someone shed any light on how this prompt works? We know the magic command to suppress the message: UDUMY = @(0), but we are more interested in why the INPUT command does not treat the space as the UniVerse message does. Thanks Steve Steve Ferries Vice President Information Technologies Total Credit Recovery Limited --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue...
Allen: I ran into a side-note recently. I've used a character-parsing loop for years like: **** MenuExit = 0; ** initialize menu-exit variable DecStr = NULL$; ** initialize decimal keypress HexStr = NULL$; ** initialize hex keypress KeyStr = NULL$; ** initialize ascii keypress * ** Enter keypress capturing code ** U2 version block. This code simply waits for all keypress events and ** returns the ASCII, HEX, and DECIMAL value(s) of that keypress by ** testing for anything else existing in the Type-Ahead variable. *LOOP ; ** UV version * AsciiChar = KEYIN() ; ** get ascii value UV version * DecChar = SEQ(AsciiChar) ; ** convert ascii to decimal UV version * DecStr := DecChar : SP1; ** build decimal keypressUV version * KeyStr := AsciiChar; ** build ascii keypress UV version * HexStr := OCONV(AsciiChar, 'MX') ; ** hex value UV version * INPUT TA.FULL,-1 ; ** TAhead full? UV version *UNTIL NOT(TA.FULL) DO REPEAT ; ** UV version * ** This code will wait for proper input and if no keypress event occurs then ** if this is called from a menu then the screen timer variable (WaitTime) is ** processed and navigation is routed to the previous menu. LOOP ; ** UD version IF NOT(WaitTime) THEN ; ** UD version INPUT AsciiChar,1: UNFILTERED ; ** get a raw byteUD version END ELSE ; ** UD version INPUT AsciiChar,1: FOR WaitTime UNFILTERED THEN ; ** UD version NULL ; ** UD version END ELSE; ** UD version IF I.VALUE = NULL$ THEN I.VALUE = WCHAR ; ** UD version AsciiChar = CHAR(13) ; ** UD version MenuExit = 1; ** UD version END ; ** UD version END; ** UD version DecChar = SEQ(AsciiChar); ** convert to decimalUD version HexStr := OCONV(AsciiChar, 'MX'); ** convert to hexUD version DecStr := DecChar : SP1 ; ** build decimal string UD version KeyStr := AsciiChar ; ** build ascii UD version UNTIL NOT(SYSTEM(14)) DO REPEAT ; ** UD version * ** End of Include **** >From within other BASIC code, where I want to manage data input, as opposed to character input, I'd do something like: **** ECHO OFF; ** turn echo off to control output DataInputStr$ = NULL$ LOOP WaitTime = 0 INCLUDE DTABP,INCLUDES DATA.INPUT ...place some character test code here (e.g CR$ / LF$ / TAB$ / ESC$ / etc) UNTIL LastHex = '0A' OR LastHex = '0D' DO ...place processing code here... * ** Update the Data Input here (non screen-editor input) DataInputStr$ := KeyStr CRT KeyStr : REPEAT ECHO ON; ** turn echo back on **** In D3 we had no problem with this code. However, in UniData, we were having some problems with slow network connections, in that characters would seem to be dropped or merged within the character-processing loop. So I'm guessing UD's version of this process is a little less robust (but maybe not). I never tested the UV code to see if this this latency problem occured. Also, terminal types never made any difference because we'd define page and arrow keys in common like: ...in Include NULL$ = '' PgUpField = 15 PgDnField = 16 PageUpKey = TermInfoRec PageDownKey = TermInfoRec ...in main program key processing loop we might do IF DataInputStr$ = NULL$ THEN IF KeyStr = PageUpKey THEN ...do something IF KeyStr = PageDownKey THEN ...do something else ...etc... END Now it doesn't matter what terminal type people are using, as long as it's defined at login. Bill >-Original Message- >From: [EMAIL PROTECTED] [mailto:owner-u2- >[EMAIL PROTECTED] On Behalf Of Allen Egerton >Sent: Wednesday, April 30, 2008 2:32 AM >To
RE: [U2] Press any key to continue...
If I could extend the question just a little ... would anyone like to share their Standard.Input.Sub that they call from all their input screens. Its always illuminating to see how others do it. -Baker --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue...
On a lot of screens here , I force end-users to type 'x' to exit (per the following code) so that they do not bypass an error message screen. I also use square brackets [#] on a single-character prompts and triangular brackets on multi-character prompts <#> so that end-users know what to expect. --Bill * Error.Prompt: crt @(-1) crt @(10,10) : ' Descriptive Error Message ' : crt @(10,11) : ' [X] : input Ans.Error, 1 Ans.Error = upcase(Ans.Error) begin case case Ans.Error = 'X' ; null case 1; call *BEEP.BEEP.AND.SLEEP.R0 ; go Error.Prompt end case return to Main.Screen *- --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
Re: [U2] Press any key to continue...
Dennis Bartlett wrote: Ah Allen You got caught by a simple mistaken glance - the code says INPUT, 1 Not INPUT, -1 And so no sleep command is necessary as the machine will wait for the next key input, and not simply loop forever! Of course, if the user decides to leave a brick on his / her keyboard, one might run into this problem. You are absolutely correct. My apologies. -- Allen Egerton aegerton at pobox dot com --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
Re: [U2] Press any key to continue...
Come on guys. This is getting sort of silly. Why on earth would anybody want to replace the Return key with the space bar? OK if you wanted to allow ESC, but still... That single character input problem exists since Hector was a pup. Been there, done that as a junior programmer. And what do you do, if you have typed a wrong character and want to go back? Backspace won't work any more. - Doh! The way we tackled it on Pick was to use GET in a loop. There is an equivalent command in UniBasic too, I just can't remember what it is. It gets a single character at the time, and waits - INPUT ans,1 does that BTW too, so you don't need a SLEEP or RQM as Dennis suggests. AFAIK you can even set a wait time, so if nothing happens, you can display a message or log the user off. Of course you then have to decide what you want to do. So if you put a backspace in, you have to remove the previous character from the string. The beauty of it is, that you can use Escape-sequences (i.e. arrow keys) and even make programs respond to mouse clicks, if your emulator is capable of recognising them. As always, use the right tool for the job - in this case not INPUT. Allen Egerton wrote: Dennis Bartlett wrote: One way to beat this, and still allow you to use a single space as an exit character, would be to create a loop that inputs a single character, then tests if that character is a space. If so, exit the loop, if not, append that character to the end of a string, eg InputtedValue = '' Loop Input Val,1: if Val=' ' then exit InputtedValue := Val Repeat This is correct, as is the rest of Dennis' post; but I'll add one caveat. When I've written this sort of loop, it's often been necessary to add a sleep or delay in the loop. Otherwise when this process is executing the computer can use the user's entire timeslice looping, 'cause there's always something for the computer to do. Which will tend to bog the machine down for the other users, (much as a very intensive SELECT will do). Obviously this can also be dependent upon userload, hardware, operating system and Pick/U2 variant - some combinations work better than others. --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue...
Ah Allen You got caught by a simple mistaken glance - the code says INPUT, 1 Not INPUT, -1 And so no sleep command is necessary as the machine will wait for the next key input, and not simply loop forever! Of course, if the user decides to leave a brick on his / her keyboard, one might run into this problem. But you brought up an interesting point that I should have added to the original post - the possibility of trapping escape characters... A similar loop can be implemented that traps any key input, so that you don't have to be limited to using a space to exit a prompt, but rather use, for example, the ESC key. To do this one would use INPUT,-1. The problem with this approach is handling the BACKSPACE key. Eg InputtedValue = '' InpCol=1 LOOP print @(InpCol,1):@(-4): ; * position the cursor so we can handle backspace INPUT Val,-1 BEGIN CASE CASE Val=CHAR(27) ; EXIT ; * escape entered, get out of loop CASE Val=CHAR(09) ; * use TAB to go to next prompt CURRENT.PROMPT +=1 EXIT CASE Val=CHAR(08) ; * BACKSPACE.KEY InpCol -= 2 ; * cater for 1 added below InputtedVal[len(InputtedVal),1]='' ; * remove last char (if any) CASE 1; InputtedVal := Val END CASE InpCol += 1 REPEAT What is great about this approach is the ability to use arrow keys, PgUp, PgDn, Insert, End, etc. As with everything computing, the problem then is to get everyone to have the same terminal emulation running. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Allen Egerton Sent: 30 April 2008 11:32 AM To: u2-users@listserver.u2ug.org Subject: Re: [U2] Press any key to continue... Dennis Bartlett wrote: --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
Re: [U2] Press any key to continue...
Dennis Bartlett wrote: One way to beat this, and still allow you to use a single space as an exit character, would be to create a loop that inputs a single character, then tests if that character is a space. If so, exit the loop, if not, append that character to the end of a string, eg InputtedValue = '' Loop Input Val,1: if Val=' ' then exit InputtedValue := Val Repeat This is correct, as is the rest of Dennis' post; but I'll add one caveat. When I've written this sort of loop, it's often been necessary to add a sleep or delay in the loop. Otherwise when this process is executing the computer can use the user's entire timeslice looping, 'cause there's always something for the computer to do. Which will tend to bog the machine down for the other users, (much as a very intensive SELECT will do). Obviously this can also be dependent upon userload, hardware, operating system and Pick/U2 variant - some combinations work better than others. -- Allen Egerton aegerton at pobox dot com --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue...
My keyboard does not have an Any key. (The old ones are best.) =8^D --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue...
Well, the actual question asks "why" it occurs, not really "how to fix" it, So... In Universe Basic one doesn't have to define the length of an input value, tho' one can, eg INPUT ANS,1 Instead it allows any length of input, so a space bar entry might just be part of a string entered - as one could enter in response to a prompt for "Reason for discard" something like "the item was run over by a rampant forklift and is in a sorry state" even if the prompt was masked as a 20 character prompt. You will see that the input contains embedded spaces. If the system were to react to a single space, as if to interpret the space as being SPACE : CR the first space would end input of the string and you would end up with just "the" One way to beat this, and still allow you to use a single space as an exit character, would be to create a loop that inputs a single character, then tests if that character is a space. If so, exit the loop, if not, append that character to the end of a string, eg InputtedValue = '' Loop Input Val,1: if Val=' ' then exit InputtedValue := Val Repeat On exit via the entry of a single space, the string InputtedValue will contain all the inputted field. Note: the : at the end of the Input Val,1: statement makes the input prompt wait at the end of the string already entered, giving the impression that the program is actually accepting the whole string as a single entry, and not just a character at a time. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ferries Sent: 29 April 2008 09:46 PM To: u2-users@listserver.u2ug.org Subject: [U2] Press any key to continue... Hi All, We were coding a standard INPUT ANS after asking a user to "Press any key to continue...". --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue...
While INPUT ANS,1 will work most of the time, if the user decides to press the backspace key or even the ESC key, nothing will happen. An alternative is: ANS = KEYIN() CLEARINPUT Which will grab a single character (including a backspace, etc). Note: if the keystroke sends two characters (eg. an escape sequence of an editing key - like Ins, Del, Page Up, etc) then KEYIN() will only get the first character. The CLEARINPUT statement clears all additional characters from the input buffer. --Adrian DISCLAIMER: Disclaimer. This e-mail is private and confidential. If you are not the intended recipient, please advise us by return e-mail immediately, and delete the e-mail and any attachments without using or disclosing the contents in any way. The views expressed in this e-mail are those of the author, and do not represent those of this company unless this is clearly indicated. You should scan this e-mail and any attachments for viruses. This company accepts no liability for any direct or indirect damage or loss resulting from the use of any attachments to this e-mail. --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue...
INPUT ANS,1 Jerry Banker Senior Programmer Analyst IBM Certified Solutions Expert -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ferries Sent: Tuesday, April 29, 2008 2:46 PM To: u2-users@listserver.u2ug.org Subject: [U2] Press any key to continue... Hi All, We were coding a standard INPUT ANS after asking a user to "Press any key to continue...". We noticed that the program would not accept a Space Bar as a valid key; it only moves the cursor to the right. However, the Press any key to continue... message from UniVerse accepts the Space Bar as a valid key. Can someone shed any light on how this prompt works? We know the magic command to suppress the message: UDUMY = @(0), but we are more interested in why the INPUT command does not treat the space as the UniVerse message does. Thanks Steve Steve Ferries Vice President Information Technologies Total Credit Recovery Limited --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue...
Consider using... input Ans, 1 The effect of the ", 1" input will look for a single keystroke. --Bill -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Steve Ferries Sent: Tuesday, April 29, 2008 3:46 PM To: u2-users@listserver.u2ug.org Subject: [U2] Press any key to continue... Hi All, We were coding a standard INPUT ANS after asking a user to "Press any key to continue...". We noticed that the program would not accept a Space Bar as a valid key; it only moves the cursor to the right. However, the Press any key to continue... message from UniVerse accepts the Space Bar as a valid key. Can someone shed any light on how this prompt works? We know the magic command to suppress the message: UDUMY = @(0), but we are more interested in why the INPUT command does not treat the space as the UniVerse message does. Thanks Steve Steve Ferries Vice President Information Technologies Total Credit Recovery Limited --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue...
Try: INPUT ANS,1 -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ferries Sent: Tuesday, April 29, 2008 3:46 PM To: u2-users@listserver.u2ug.org Subject: [U2] Press any key to continue... Hi All, We were coding a standard INPUT ANS after asking a user to "Press any key to continue...". We noticed that the program would not accept a Space Bar as a valid key; it only moves the cursor to the right. However, the Press any key to continue... message from UniVerse accepts the Space Bar as a valid key. Can someone shed any light on how this prompt works? We know the magic command to suppress the message: UDUMY = @(0), but we are more interested in why the INPUT command does not treat the space as the UniVerse message does. Thanks Steve Steve Ferries Vice President Information Technologies Total Credit Recovery Limited --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue... - how to skip
LIST VOC NO.PAGE (Universe anyway) > -Original Message- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of #ukasz s > Sent: Wednesday, April 12, 2006 10:12 AM > To: u2-users@listserver.u2ug.org > Subject: [U2] Press any key to continue... - how to skip > > > How can I skip "Press any key to continue..." during: > LIST VOC command? > thanks for answers:-) > --- > u2-users mailing list > u2-users@listserver.u2ug.org > To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue... - how to skip
Do you mean: LIST VOC NOPAGE Ron Sharcott (3635) -Original Message- From: Lukasz s [mailto:[EMAIL PROTECTED] Sent: Wednesday, April 12, 2006 7:12 AM To: u2-users@listserver.u2ug.org Subject: [U2] Press any key to continue... - how to skip How can I skip "Press any key to continue..." during: LIST VOC command? thanks for answers:-) --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue... - how to skip
LIST VOC NOPAGE -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of #ukasz s Sent: Wednesday, April 12, 2006 8:12 AM To: u2-users@listserver.u2ug.org Subject: [U2] Press any key to continue... - how to skip How can I skip "Press any key to continue..." during: LIST VOC command? thanks for answers:-) --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ -- No virus found in this incoming message. Checked by AVG Free Edition. Version: 7.1.385 / Virus Database: 268.4.1/308 - Release Date: 4/11/2006 -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.385 / Virus Database: 268.4.1/308 - Release Date: 4/11/2006 --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
Re: [U2] Press any key to continue... - how to skip
That would be the NOPAGE keyword. Add that to the end of your statement as in: LIST VOC NOPAGE Gordon J. Glorfield Sr. Applications Developer UnitedHealthcare's Mid-Atlantic Health Plans 301-360-8839 [EMAIL PROTECTED] wrote on 04/12/2006 10:11:53 AM: > How can I skip "Press any key to continue..." during: > LIST VOC command? > thanks for answers:-) > --- > u2-users mailing list > u2-users@listserver.u2ug.org > To unsubscribe please visit http://listserver.u2ug.org/ This e-mail, including attachments, may include confidential and/or proprietary information, and may be used only by the person or entity to which it is addressed. If the reader of this e-mail is not the intended recipient or his or her authorized agent, the reader is hereby notified that any dissemination, distribution or copying of this e-mail is prohibited. If you have received this e-mail in error, please notify the sender by replying to this message and delete this e-mail immediately. --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue... - how to skip
LIST VOC (N Or LIST VOC NO.PAGE Or press N on the first 'Press any key.' to skip all the rest. > -Original Message- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of #ukasz s > Sent: Wednesday, April 12, 2006 10:12 AM > To: u2-users@listserver.u2ug.org > Subject: [U2] Press any key to continue... - how to skip > > > How can I skip "Press any key to continue..." during: > LIST VOC command? > thanks for answers:-) > --- > u2-users mailing list > u2-users@listserver.u2ug.org > To unsubscribe please visit http://listserver.u2ug.org/ > > -- > No virus found in this incoming message. > Checked by AVG Free Edition. > Version: 7.1.385 / Virus Database: 268.4.1/309 - Release > Date: 4/11/2006 > > -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.385 / Virus Database: 268.4.1/309 - Release Date: 4/11/2006 --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue... - how to skip
type 'N' -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Lukasz s Sent: 12 April 2006 15:12 To: u2-users@listserver.u2ug.org Subject: [U2] Press any key to continue... - how to skip How can I skip "Press any key to continue..." during: LIST VOC command? thanks for answers:-) --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ __ This email has been scanned by the MessageLabs Email Security System. For more information please visit http://www.messagelabs.com/email __ __ This email has been scanned by the MessageLabs Email Security System. For more information please visit http://www.messagelabs.com/email __ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Press any key to continue... - how to skip
You can either: Press N at the prompt itself or Use the NOPAGE option LIST VOC NOPAGE Brian > -Original Message- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of Lukasz s > Sent: 12 April 2006 15:12 > To: u2-users@listserver.u2ug.org > Subject: [U2] Press any key to continue... - how to skip > > How can I skip "Press any key to continue..." during: > LIST VOC command? > thanks for answers:-) > --- > u2-users mailing list > u2-users@listserver.u2ug.org > To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/