;+
; Project     : SOLAR-B - EIS
;
; Name        : EIS_CPT_PARSE_ORL_NUMBER
;
; Purpose     : Parses the orl number command.
;
; Explanation : Parses the orl number command.
;
; Use         : < result = eis_cpt_parse_orl_number ( operand ) >
;
; Inputs      : operand : STRING operand
;
; Opt. Inputs : None.
;
; Outputs     : result   : INT flag :
;                            1 : processed OK.
;                            0 : processing failed.
;
; Opt. Outputs: None.
;
; Keywords    : None.
;
; Calls       : None.
;
; Common      : None.
;
; Restrictions: None.
;
; Side effects: May output ASCII files.
;
; Category    : EIS_CPT.
;
; Prev. Hist. : None.
;
; Written     : Martin Carter RAL 11/05/07
;
; Modified    : Version 0.0, 11/05/07, MKC
;
; Version     : 0.0, 11/05/07
;-
;**********************************************************

FUNCTION eis_cpt_parse_orl_number, operand

  ; decipher string operand

  IF NOT STREGEX(operand, '^[0-9][0-9][0-9]$', /BOOLEAN) THEN BEGIN

    eis_cpt_message, 'ERROR, NUMBER COMMAND OPERAND NOT IN CORRECT FORMAT', /INFORMATIONAL

    GOTO, error

  ENDIF

  int_value = 0

  READS, operand, int_value, FORMAT='(I3.3)'

  ; NB does not do anything with OG number

  RETURN, 1

error :

  ; issue routine name

  MESSAGE, 'ERROR', /INFORMATIONAL

  ; return error flag

  RETURN, 0

END





