View previous topic :: View next topic
|
Author |
Message |
vramya
New User
Joined: 07 Nov 2008 Posts: 13 Location: US
|
|
|
|
I have a panel that gets a input of a variable with 7 characters. The constraint is:
The input should be exactly 7 Digits only.
I have given the command as below:
)PROC
VER(&VAR1,RANGE,0000000,9999999)
VER(&VAR1,NB)
This makes sure that only numeric can be entered and it must not be blank.
Apart from Length command, do we have any other option to check in the panel program itself to check for count of 7 digits like the Range option given in the above example.
Thanks. |
|
Back to top |
|
|
vikash singh
New User
Joined: 12 May 2007 Posts: 15 Location: noida
|
|
|
|
Use following code:
VER(&VAR1,PICT,'NNNNNNN') |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10873 Location: italy
|
|
|
|
when You look at a manual to find out about PANELS, what manual do You use
not certainly the tso REXX reference
why not post to the correct forum?and use the correct terms?
There are no such things like Rexx panels,
panels are an ISPF object,
dialogs, which disply panels can be written in Rexx...
moved where it belongs |
|
Back to top |
|
|
Pedro
Global Moderator
Joined: 01 Sep 2006 Posts: 2547 Location: Silicon Valley
|
|
|
|
Quote: |
Apart from Length command |
What is wrong with the length command? That is, you can invoke rexx from the panel. I think you can use the length function of rexx. |
|
Back to top |
|
|
vramya
New User
Joined: 07 Nov 2008 Posts: 13 Location: US
|
|
|
|
Thanks Vikash. It worked.
There is no disadvantage I came across using length command.
But I have more than 10 varaibles in my program.
I have to use length function for all the variables and display appropriate message.
If I have a command like PICT as mentioned in the previous post, I can directly use them in the declaration itself.
Enrico,
Thanks for moving the post appropriately. I have started working on REXX for the past 1 week and I will take care of these things from my next post. |
|
Back to top |
|
|
vikash singh
New User
Joined: 12 May 2007 Posts: 15 Location: noida
|
|
Back to top |
|
|
|