MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Initialize rexx variables using interpret command

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> TSO and ISPF
View previous topic :: View next topic  
Author Message
Dibakar
Advanced


Joined: 02 Dec 2002
Posts: 700
Topics: 63
Location: USA

PostPosted: Wed Sep 28, 2005 4:20 am    Post subject: Initialize rexx variables using interpret command Reply with quote

I have some variables a1, a2, ... a9 used in a panel. What would be an efficient way to initialize them.

I tried the following but it is giving syntax error.

Code:

do i = 1 to 9; interpret 'a'i = ""''; end   
Back to top
View user's profile Send private message Send e-mail
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12375
Topics: 75
Location: San Jose

PostPosted: Wed Sep 28, 2005 4:24 am    Post subject: Reply with quote

Dibakar,

Did you check this topic ?

http://mvsforums.com/helpboards/viewtopic.php?t=3983&highlight=initialize

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Dibakar
Advanced


Joined: 02 Dec 2002
Posts: 700
Topics: 63
Location: USA

PostPosted: Wed Sep 28, 2005 4:46 am    Post subject: Reply with quote

I missed one quote. Following code is working.

Code:

do i = 1 to 9; interpret 'a'i' = ""'; end
Back to top
View user's profile Send private message Send e-mail
semigeezer
Supermod


Joined: 03 Jan 2003
Posts: 1014
Topics: 13
Location: Atlantis

PostPosted: Wed Sep 28, 2005 7:59 am    Post subject: Reply with quote

Probably the most efficient way is:

Parse value "" with a1 a2 a3 a4 a5 a6 a7 a8 a9

2nd would be to use the value() function.

As usual, Interpret can be used as a last resort.
Back to top
View user's profile Send private message Visit poster's website
Dibakar
Advanced


Joined: 02 Dec 2002
Posts: 700
Topics: 63
Location: USA

PostPosted: Wed Sep 28, 2005 9:35 pm    Post subject: Reply with quote

kolusu,

that was quick!

actually i was searching for array, if i had serached for interpret then i wouldn't have missed.

thanks,
diba.
Back to top
View user's profile Send private message Send e-mail
Dibakar
Advanced


Joined: 02 Dec 2002
Posts: 700
Topics: 63
Location: USA

PostPosted: Thu Oct 06, 2005 1:48 am    Post subject: Reply with quote

Hi Semigeezer,

I didn't notice your reply earlier, only kolosus's reply was visible then. Cannot understand why?

Thanks for the answers,
Diba.
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> TSO and ISPF All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group