You know, posters at these listservs can be enormously helpful, but there are other days... Can't a one of you answer his actual question? One third of Mr Clarke's reply addressed it; the other two ignored it.
Mr Swarbrick, I tried your program, with the addition of Mar Dissen's debugging command, and got this:
SET VARNAME = &VAR
SET VARNAME = MYVAR
SET &VARNAME = &VAL
SET &VARNAME = MYVAL
ISPEXEC VPUT (&VARNAME) PROFILE
ISPEXEC VPUT (MYVAL) PROFILE
In other words, it worked properly for me. How are you calling your program? At this end I did it this way:
==> tso <clist name> var(myvar) val(myval)
By the way, my expostulation notwithstanding, I agree with most of what they said: Doing it in REXX would be easier, and if you're going to do it in CLIST you might consider using the PROC statement suggested by Mr Hewson.
---
Bob Bridges,
robhb...@gmail.com, cell
336 382-7313
/* Give a man a program and you'll frustrate him for a day. Teach a man to program and you'll frustrate him for a lifetime. -Francesco Napoletano @napolux */
________________________________________
From: 'Frank Clarke' via ISPF discussion list <
ispf-...@nd.edu>
Sent: Wednesday, May 19, 2021 07:52
(a) why, in 2021, is anyone writing CLIST?
(b) SET &VARNAME = &&VAL /* This is a guess; I haven't written CLIST since 1988, 1/3 century ago.
(c) in REXX: $z = Value(varname,val) /* loads VAL to VARNAME */
-----Original Message-----
From:
ispf-...@nd.edu <
ispf-...@nd.edu> On Behalf Of Binyamin Dissen
Sent: Wednesday, May 19, 2021 06:50
Several errors.
I would suggest adding
CONTROL LIST CONLIST SYMLIST
so you see what is going on.
Would be a lot easier in REXX.
________________________________________
From: 'Hewson, Bruce ' via ISPF discussion list <
ispf-...@nd.edu>
Sent: Wednesday, May 19, 2021 05:59
PROC 2 VAR VAL
--- From:
ispf-...@nd.edu <
ispf-...@nd.edu> On Behalf Of Swarbrick, Frank
Sent: Wednesday, May 19, 2021 05:49