;+ ; NAME: checkargnum ; checks that the parent routine actually had the right number of args ; passed to it. ; ; INPUTS: ; nparams the output of N_params() for the calling routine ; nrequired how many params are required ; usagestring the string to print if there are too few args ; ; HISTORY: ; Began 2002-03-30 17:58:12 by Marshall Perrin ; - PRO checkargnum,nparams,nrequired,usagestring if nparams LT nrequired then begin print,"Incorrect number of arguments." print,'Syntax: '+usagestring stop return endif end