
------------------------------------------------------------------------------
1.16 Delete specified program. <Main,Alarm>
------------------------------------------------------------------------------
[Name]
cnc_delete
[Syntax]
#include <data.h>
#include <fwindow.h>
short cnc_delete( long number ) ;
[Arguments]
number Program number.
[Return]
EW_OK( 0) Successful.
EW_DATA( 5) The specified NC program is not registered in CNC.
EW_PROT( 7) Tape memory of CNC is protected, or the target program
is protected.
EW_BUSY(-1) In the CNC, the specified-program delete command was
rejected.
This code is returned if any of the following conditions
exists when this command is executed.
- The CNC is performing other window command processing
(downloading, collating, uploading, or program number
list reading).
- An NC program is running (automatic operation signal
OP<F000#7> is on).
- A P/S 000, P/S 101, or BP/S alarm condition has occurred.
[Description]
Deletes the specified NC program registered in CNC.
If the specified program is used for the current automatic operation,
it can't be deleted.
Specify the program number of NC program to be deleted in "number"
with binary format.