SETSYSTEMVAL acting strange - VMS

Robert J.M. Edis robert.edis@creatcomp.com
Fri, 30 Apr 1999 10:56:59 -0400


Bill

In the QUICK screen the symbol declared local to that process.  When a DCL
command is spawned, it is a new process and knows nothing about the symbol
declared in the QUICK.  It does however know about the symbol declared in
the login.com as that is common to all interactive processes under the
current login session (and batch processes too).

To make the DCL process aware of the new symbol value it has to be declared
global, not local.  I have found this a problem in the past and usually end
up declaring the value as a logical in the JOB table instead.  This does
transfer to the DCL process.

Blue
PowerHouse consultant
Rhode Island, USA

Disclaimer:
The opinions and ideas expressed in this message are my own and have no
relationship to my current employer, Initial Technical Staffing, its client
CCI, or any of CCI's clients.



	-----Original Message-----
	From:	Bill.Michael@ipaper.com [SMTP:Bill.Michael@ipaper.com]
	Sent:	Friday, April 30, 1999 10:43 AM
	To:	        -         (052)powerh-l(a)lists.swau.edu
	Subject:	SETSYSTEMVAL acting strange - VMS

	In Quick (7.10G1), I'm attempting to change a symbol, so that the
value can be
	used in other screens/reports/etc. It seems to be working
"sometimes", but not
	consistently.

	For example, if MDS$MILL_NO is set to "338" by my login.com, I can
call the
	following code in the INITIALIZE procedure of a screen;

	   LET T-CMD = "DELETE/SYMBOL/LOCAL MDS$MILL_NO"
	   RUN COMMAND T-CMD REFRESH SCREEN
	   LET T-CMD = "DELETE/SYMBOL/GLOBAL MDS$MILL_NO"
	   RUN COMMAND T-CMD REFRESH SCREEN
	   IF NOT SETSYSTEMVAL("MDS$MILL_NO",T-MILL,SYMBOL)
	     THEN ERROR "*E* Could not set Mill number. Please contact IS."
	   LET T-HOLD-MILL = GETSYSTEMVAL("MDS$MILL_NO",SYMBOL)
	   IF T-HOLD-MILL <> T-MILL
	     THEN ERROR "*E* Could not set Mill number. Please contact IS."

	Let's say T-MILL is 113. I get no errors, and this appears to work
fine
	_in_this_screen_ - but calling a com file using "run command", for
example, and
	showing the symbol in the com file, still shows 338!

	If I compile the screen and say "go", verify that MDS$MILL_NO is
indeed 113
	within the screen, then exit, here is what I see;

	QUICK session completed.

	> $SHOW SYM MDS$MILL_NO
	  MDS$MILL_NO == "113"
	> E
	[MICHAEL.SOURCE]SHOW SYM MDS$MILL_NO
	  MDS$MILL_NO == "338"
	[MICHAEL.SOURCE]

	Now, I've deleted the symbol at the local and global levels within
the screen.
	Then I've created it with the value 113. Where does the 338 come
from???

	It appears that QUICK is "storing" symbol values somewhere and
"restoring" them
	- behavior that should NOT occur, since the whole point of
SETSYSTEMVAL is to
	change such symbols!

	Bill
	= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
= = = =
	Subscribe: "subscribe powerh-l" in message body to
majordomo@lists.swau.edu
	Unsubscribe: "unsubscribe powerh-l" in message to
majordomo@lists.swau.edu
	powerh-l@lists.swau.edu is gatewayed one-way to
bit.listserv.powerh-l
	This list is closed, thus to post to the list, you must be a
subscriber.
= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
Subscribe: "subscribe powerh-l" in message body to majordomo@lists.swau.edu
Unsubscribe: "unsubscribe powerh-l" in message to majordomo@lists.swau.edu
powerh-l@lists.swau.edu is gatewayed one-way to bit.listserv.powerh-l
This list is closed, thus to post to the list, you must be a subscriber.