[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference bulova::decw_jan-89_to_nov-90

Title:DECWINDOWS 26-JAN-89 to 29-NOV-90
Notice:See 1639.0 for VMS V5.3 kit; 2043.0 for 5.4 IFT kit
Moderator:STAR::VATNE
Created:Mon Oct 30 1989
Last Modified:Mon Dec 31 1990
Last Successful Update:Fri Jun 06 1997
Number of topics:3726
Total number of notes:19516

767.0. "DECterm problems." by 48284::DAN_M (Maya DAN) Thu May 11 1989 06:50

    One of my customers(important Financial PROJCET for CREDIT LYONNAIS)
    has problems with DECterm.
    he wants to run a V220 soft in a DECterm window from a DECwindows
    application in C.
    Normaly it works fine but in some special cases he has failures:
    -first he creates a DECterm window.
    -second , he launch LOGINOUT.EXE in that DECterm window and asks
    for a command file to be executes after the login.com.In the command
    file , he assignes a few logical names and then he runs his soft.
    But , if he puts the following request:
    write sys$output F$getjpj(process_number,"Terminal")
    the answer is ab empty string !
    
    or when he asks SHOW TERM in the command file, the answer is:
    %SYSTEM-F-IVDEVNAM, invalid device name.
    
    What does that mean?Isn't his DECterm window a terminal like others?
    
    Following is the way he does it:
    
    -first create a DECterm window.
    	stat =DECTermPort (0,0,list,result_device_name, length_of_dev);
    -second ,he launch LOGINOUT.EXE in that DECterm window using:
     SYS$CREPRC (  ,
    		 LOGINOUT.EXE,				/*  image name*/
    		 CLI.COM_file,				 /*   SYS$INPUT*/
    		 new_window_dev_name,		/*   SYS$OUTPUT */
    		 new_window_dev_n        ,,,,,,)
    The 3rd parameter is the name of the command file to be executed
    after login.com.He assigns in it a few logical names and then he
    runs the soft.
    It works very good but if he puts an INQUIRE in the command file...it
    doesn't wait for any keyboard input.May be somthing is wrong with
    the SYS$INPUT or SYS$COMMAND.
    As the SYS$OUTPUT was directed on the terminal, he puts in the command
    file (to try) ASSIGN SYS$OUTPUT SYS$COMMAND.Of course in this case,
    if he puts READ SYS$COMMAND instaed of INQUIRE, is o.K.-the keyboard
    input is expected.BUT, it still doesn't wotk because it makes the
    application display fail.
    thank you to help me to answer to my customer.
    Maya
    

T.RTitleUserPersonal
Name
DateLines
767.1DECterm conference8345::WESTI'm just visiting this planet.Thu May 11 1989 10:037
    You may want to check out the DECterm conference also.  
    
    Hit KP7 to select...
    
    				-=> Jim <=-
    

767.256733::MESSENGERBob MessengerThu May 11 1989 18:417
Re: .0

What device name is he using?  A TW: device will be reported as a terminal
but a PY: device (the other end of the TW-PY pty device pair) will not.

				-- Bob

767.3HANNAH::DECW$DISK:[PUBLIC]DECTERM.NOTE38863::DERAMODaniel V. {AITG,ZFC}:: D&#039;EramoThu May 11 1989 19:448
	The DECterm conference is not at HANNAH::DECTERM.  It is at

		HANNAH::DECW$DISK:[PUBLIC]DECTERM.NOTE

	where HANNAH is currently node 55.413 or 56733.

	Dan

767.4From my experience with CHILD:7130::LOMICKAJJeff LomickaMon May 15 1989 12:1037
First - is there a good reason why you aren't using LIB$SPAWN instead
of $CREPRC.  If you can live within the restrictions of subprocesses,
all of this is MUCH easier with LIB$SPAWN than with SYS$CREPRC.

Whein doing a LIB$SPAWN, you can give both "input" and "output" as the
created TWAn: device, and "@filename" as the command line.  This always
works well.

If you insist, when doing a $CREPRC of LOGINOUT.EXE into a DECTerm
window, the correct values for "input", "output", and "error" are:

	input - Your command file (this will be SYS$INPUT and SYS$COMMAND).
	output - The returned TWAn: device from DECW$TERM_PORT.
	error - The translation of DECW$DISPLAY.

Better yet would be to use the returned TWAn: as "input" also, but then
there is no good way to tell the new process what to run.  If you do
give a FILE as "input", you must ensure the following:

	- In SYLOGIN.COM, you must change all "SET TERM" commands to be
	"SET TERM SYS$OUTPUT:" commands.  Any references to the user's
	terminal must be made via SYS$OUTPUT, becuase SYS$INPUT and
	SYS$COMMAND are the input file.

	- You MUST specify the NOPASSWORD option to LOGINOUT.  It
	refuses to read username and password from a non-terminal.

You seem to have some understainding of the logical name problems - and
seem to be on the right track.  A

	$ DEFINE SYS$INPUT SYS$OUTPUT:
	$ DEFINE SYS$COMMAND SYS$OUTPUT:

will get you a long way.  A /EXEC might help also.
Note the use of ":".