2
! Example 16, MIDAS procedure exa16.prg
4
DEFINE/PARAM P1 ? ? "Enter FITS file name:"
6
DEFINE/LOCAL INA/C/1/80 " " all ! that fills all elements of INA with blanks
7
DEFINE/LOCAL K/I/1/2 0,0
9
K = M$INDEX(P1,".mt") ! test, if type of FITS file entered
11
WRITE/KEYW INA {P1}.mt ! if not, append type
13
WRITE/KEYW INA {P1} ! if yes, no need to append type
15
INTAPE/FITS 1 midd {ina} fnn | $more
16
! but if we want to save the no. of axes of the FITS file
17
! we do not use the keyword name INA but it's contents
18
K = M$VALUE({ina},naxis)
19
WRITE/OUT we have {K} axes