[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: David: for your book ?



Martin Schultz <martin.schultz@dkrz.de> writes:
> Hi,
> 
>    Testing IDL's capabilities is always dangerous: you might get more
> than you ask for!
> 
> What would you expect to get out of the following:
> 
> test = [ 'dir1/', 'directory2/', 'another_directory/' ]
> print,strmid(test,0,strlen(test)-1)

Hmm, I got an error message!

IDL> test = [ 'dir1/', 'directory2/', 'another_directory/' ]
IDL> print,strmid(test,0,strlen(test)-1)
% STRMID: Expression must be a scalar in this context: <LONG      Array[3]>.
% Execution halted at:  $MAIN$                 

IDL> print, !version
{ alpha OSF unix 5.2 Oct 30 1998}

Is this something new in IDL 5.3?

Craig


-- 
--------------------------------------------------------------------------
Craig B. Markwardt, Ph.D.         EMAIL:    craigmnet@cow.physics.wisc.edu
Astrophysics, IDL, Finance, Derivatives | Remove "net" for better response
--------------------------------------------------------------------------