# AG\_IATIMEOUT

> [HTML Version](ag_iatimeout.htm)

_Reviewed and revised December 2023_

**tab(-10, AG\_IATIMEOUT); opcode, timesecs; chr(127);**     [Tab(-10,x) Syntax Notes](ag_xxx_syntax-notes.md)

AG\_IATIMEOUT (79) retrieves or sets the inactivity timeout period. 

This function has both a [subroutine and a print tab implementation](subroutine-print-pairs.md).

**Parameters**

_opcode_ should be 1 (MXOP\_SET) to set the timeout, and 1 (MXOP\_gET) to retrieve it (in seconds). Since the default opcode is 0 (MXOP\_get) and the _timesecs_ argument is ignored in the case of the retrieve operation, both arguments can be eliminated when retrieving the timeout.

**Response**

For opcode 0, the current inactivity timeout value in seconds:

_timesecs_ <CR>

Note that this differs from the IATIMEOUT parameter in the system ini file, which uses units of minutes.

**Examples**

Retrieve:

? tab(-10,AG\_IATIMEOUT);chr(127);

input "",timeout'seconds



Set:

? tab(-10,AG\_TIMEOUT);"1,";timeout'seconds;chr(127);



**Comments**

Note that in the case of ATE, if the server-side timeout expires, the job will receive error 254, whereas if the client-side timeout expires, the job will experience this as a hang-up (error 250). See [Job Terminations](job_terminations.md) for more details on how hang-ups are handled.

**See Also**

•	[MX\_IATIMEOUT](mx_iatimeout.md)[xs](keyword-types.md)

•	[IATIMEOUT](iatimeout_sp.md)[sp](keyword-types.md)

**History**

2011 June, A-Shell 5.1.1221:  Command added to A-Shell