$TsoCan: Difference between revisions

From m204wiki
Jump to navigation Jump to search
m (1 revision)
mNo edit summary
Line 2: Line 2:
<span class="pageSubtitle"><section begin="desc" />Cancel program invoked via $TsoAtt<section end="desc" /></span>
<span class="pageSubtitle"><section begin="desc" />Cancel program invoked via $TsoAtt<section end="desc" /></span>


<p class="warning">Most Sirius $functions have been deprecated in favor of Object Oriented methods. The OO equivalent for the $TsoCan function is [[to be entered]].</p>
<p class="warning">Most Sirius $functions have been deprecated in favor of Object Oriented methods. There is no OO equivalent for the $TsoCan function.</p>


This function cancels a specific task running a program invoked via $TsoAtt or all such tasks initiated by the current user.<blockquote> This function requires the special version of the TSO full screen interface to ''Model 204'' that is distributed by Sirius Software. </blockquote>  
This function cancels a specific task running a program invoked via $TsoAtt or all such tasks initiated by the current user.<blockquote> This function requires the special version of the TSO full screen interface to ''Model 204'' that is distributed by Sirius Software. </blockquote>  
Line 9: Line 9:


The first argument is a number that is the task id of the "task" for which status is requested. This is an optional argument and if omitted indicates that you want all tasks to be cancelled.
The first argument is a number that is the task id of the "task" for which status is requested. This is an optional argument and if omitted indicates that you want all tasks to be cancelled.
==Syntax==
==Syntax==
<p class="syntax"><section begin="syntax" /> %RESULT = $TsoCan(task_id)
<p class="syntax"><section begin="syntax" /> %RESULT = $TsoCan(task_id)
Line 16: Line 17:
<p class="caption">%RESULT is set either to the status code for the cancelled task or to an error code.</p>
<p class="caption">%RESULT is set either to the status code for the cancelled task or to an error code.</p>


$TsoCan normally returns the status code of the cancelled task. If there is some error that prevents the task from being cancelled, however, a negative error code is returned to indicate the problem.


$TsoCan normally returns the status code of the cancelled task. If there is some error that prevents the task from being cancelled, however, a negative error code is returned to indicate the problem.<p>
<p class="code">
-1 - Connection broken
  -1 - Connection broken
-4 - Not a TSO full screen IODEV (IODEV 11)
  -4 - Not a TSO full screen IODEV (IODEV 11)
-8 - Incorrect version of TSO interface
  -8 - Incorrect version of TSO interface
  -20 - LOUTPB too small
  -20 - LOUTPB too small
</p>
</p>
Line 26: Line 28:
</p>
</p>


The following program invokes a program called 'COMPRESS' in the user's TSO address space with a parameter of 'DSN(JUNK.CNTL)', issues a FIND while 'COMPRESS' is running, and then cancels the 'COMPRESS' command if it is still running.


The following program invokes a program called 'COMPRESS' in the user's TSO address space with a parameter of 'DSN(JUNK.CNTL)', issues a FIND while 'COMPRESS' is running, and then cancels the 'COMPRESS' command if it is still running.
<p class="code"> B
<p class="code"> B
   
   
Line 42: Line 44:
  END
  END
</p>
</p>
<p class="code">
<ul>
<li>&JAPF


<ul class="smallAndTightList">
<li>[[Japanese $Functions]]
</ul>
</ul>
   
   
Line 53: Line 52:
<p class="caption">Products authorizing $TsoCan
<p class="caption">Products authorizing $TsoCan
</p>
</p>


[[Category:$Functions|$TsoCan]]
[[Category:$Functions|$TsoCan]]

Revision as of 20:52, 8 February 2011

<section begin="desc" />Cancel program invoked via $TsoAtt<section end="desc" />

Most Sirius $functions have been deprecated in favor of Object Oriented methods. There is no OO equivalent for the $TsoCan function.

This function cancels a specific task running a program invoked via $TsoAtt or all such tasks initiated by the current user.

This function requires the special version of the TSO full screen interface to Model 204 that is distributed by Sirius Software.

The $TsoCan function accepts one argument and returns a numeric status code or count.

The first argument is a number that is the task id of the "task" for which status is requested. This is an optional argument and if omitted indicates that you want all tasks to be cancelled.

Syntax

<section begin="syntax" /> %RESULT = $TsoCan(task_id) <section end="syntax" />

$TsoCan Function

%RESULT is set either to the status code for the cancelled task or to an error code.

$TsoCan normally returns the status code of the cancelled task. If there is some error that prevents the task from being cancelled, however, a negative error code is returned to indicate the problem.

-1 - Connection broken -4 - Not a TSO full screen IODEV (IODEV 11) -8 - Incorrect version of TSO interface -20 - LOUTPB too small

$TsoCan return codes

The following program invokes a program called 'COMPRESS' in the user's TSO address space with a parameter of 'DSN(JUNK.CNTL)', issues a FIND while 'COMPRESS' is running, and then cancels the 'COMPRESS' command if it is still running.

B %TASKID = $TsoAtt( 'COMPRESS', , 'DSN(JUNK.CNTL)') FIND1: IN BIGFILE FIND ALL RECORDS FOR WHICH NAME IS LIKE 'SM*' END FIND %RC = $TsoCan( %TASKID ) ... END

Products authorizing $TsoCan