/****************************** REXX *******************************/
/* This exec must be run in ISPF. It displays panel named newtool */
/* and gets the name of a data set from input fields named ntproj, */
/* ntgroup, nttype, and ntmem. If no member name is specified (the*/
/* data set is sequential) the data set name does not include it. */
/* If a member name is specified, the member is added to data set */
/* name. The fully-qualified data set name is then inserted into a*/
/* TRANSMIT command that includes single quotation marks and the */
/* destination, which was received from an input field named ntdest*/
/*******************************************************************/
ADDRESS ispexec
"DISPLAY PANEL(newtool)"
ADDRESS tso /* re-establish the TSO host command environment */
IF ntmem = '' THEN /* member name is blank */
DO
dsname = ntproj'.'ntgroup'.'nttype
"TRANSMIT" ntdest "DA('"dsname"')"
END
ELSE
DO
dsname = ntproj'.'ntgroup'.'nttype'('ntmem')'
"TRANSMIT" ntdest "DA('"dsname"')"
END