![]() | |
![]() |
| | Thread Tools | Display Modes |
#21
| |||
| |||
|
|
To check the file handle... IF NOT(ASSIGNED(CM.FILE)) THEN OPEN 'CM' TO CM.FILE |
#22
| |||
| |||
|
|
To check the file handle... |
#23
| |||
| |||
|
|
Where do you assign a value to AT.TIME? OOPS! Thanks, Mecki! When you open the file: 001 SUBROUTINE HELLO(outp,inp) 002 COMMON /HELLO/ AT.TIME, CM.FILE 003 IF AT.TIME # @TIME THEN 004 OPEN "CM" TO CM.FILE ELSE STOP... ---> AT.TIME = @TIME <---------- insert this new line 005 END If you don't like AT.TIME (that wil fail if subr runs precisely at midnight, @TIME = 0, since common variables are automaticlly initialized to 0), you can use other flags, e.g., INIT.FLAG 1 or 0. I like usnig @PATH, which changes whenever you logto somewhere else. You'd hate to use the other account's file. You will still get a "Variable not assigned a value" error message. |
#24
| |||
| |||
|
![]() |
| Thread Tools | |
| Display Modes | |
| |