comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » IDL Save File Mystery
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
IDL Save File Mystery [message #69446] Thu, 07 January 2010 20:08
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Folks,

Here is our first mystery for 2010. Consider the following
IDL procedure:

Pro testobjview
s = obj_New('IDLgrtext', 'This is some text')
xobjview, s
END

Starting in a fresh IDL session, I execute the following
code as a batch file.

;******************************************************
.compile testobjview
Resolve_All, CLASS=['IDLExobjviewwid',$
'IDLExViewGroup', $
'IDLExObjView', $
'IDLExinscribingview', $
'IDLgrText']
IRESOLVE
Save, FILE='C:\IDL\testobjview.sav', /ROUTINES
;*****************************************************

I now exit IDL and drag the save file to the IDL
Virtual Machine. It doesn't run. Tells me to contact
the author of the program. Unfortunately, he is still
drinking rum and cokes in the Bahamas. :-(

I now start up IDL and restore the save file and run
it:

IDL> Restore, '='C:\IDL\testobjview.sav'
IDL> testobjview

It runs perfectly and nothing else is compiled in this
new IDL session.

Now, I do the very same thing as before, except this time
in the batch file I actually call TextObjView instead of
compiling it:

;******************************************************
testobjview
Resolve_All, CLASS=['IDLExobjviewwid',$
'IDLExViewGroup', $
'IDLExObjView', $
'IDLExinscribingview', $
'IDLgrText']
IRESOLVE
Save, FILE='C:\IDL\testobjview.sav', /ROUTINES
;*****************************************************

This time, when I exit IDL and drag the save file to the
Virtual Machine, it runs perfectly.

What in the world is going on here!? My theory, obviously,
is that something is *not* getting compiled. But, what!?

Cheers,

David

P.S. Those of you who try this in a version of IDL that is
*not* 7.1 will need to substitute "ITRESOLVE" for "IRESOLVE".
The routine has been renamed in IDL 7.1.

--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Re: ps_start problems in idl 7.1
Next Topic: chunk indexing like

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 17:44:49 PDT 2025

Total time taken to generate the page: 0.00494 seconds