Re: Compiling programmes within programmes. [message #36573] |
Wed, 08 October 2003 15:24 |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
Karthikayan Balakrishnan writes:
> I may have misread your post, anyway here is your original message:
> -----------------------------------------
> It looked something like this:
>
> PRO COYOTE_MAKE
> Resolve_Routine, 'coyote1'
> Resolve_Routine, 'coyote2', /Is_Function
> Resolve_Routine, 'coyote3'
> ...
> ...
> Resolve_All
> Save, /Routines, File='coyote.sav'
> END
>
> I just put all my program modules at the beginning to
> make sure they are compiled (this part only took 4-5
> iterations :-), the Resolve_All routine at the end
> catches all the library routines I am using, and I
> am set. Now, as I add modules to the application, I
> just include the name in here and I can make a save
> file whenever I need it by typing "coyote_make" at the
> IDL command line. Pretty slick, I think.
Did I say "slick"!? I meant "ugly". :-)
Cheers,
David
--
David W. Fanning, Ph.D.
Fanning Software Consulting, Inc.
Phone: 970-221-0438, E-mail: david@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
|
|
|
|
Re: Compiling programmes within programmes. [message #36575 is a reply to message #36574] |
Wed, 08 October 2003 14:37  |
Karthikayan Balakrish[2]
Messages: 4 Registered: October 2003
|
Junior Member |
|
|
I may have misread your post, anyway here is your original message:
-----------------------------------------
It looked something like this:
PRO COYOTE_MAKE
Resolve_Routine, 'coyote1'
Resolve_Routine, 'coyote2', /Is_Function
Resolve_Routine, 'coyote3'
...
...
Resolve_All
Save, /Routines, File='coyote.sav'
END
I just put all my program modules at the beginning to
make sure they are compiled (this part only took 4-5
iterations :-), the Resolve_All routine at the end
catches all the library routines I am using, and I
am set. Now, as I add modules to the application, I
just include the name in here and I can make a save
file whenever I need it by typing "coyote_make" at the
IDL command line. Pretty slick, I think.
|
|
|
Re: Compiling programmes within programmes. [message #36576 is a reply to message #36575] |
Wed, 08 October 2003 14:42  |
Karthikayan Balakrish[2]
Messages: 4 Registered: October 2003
|
Junior Member |
|
|
Once again, I got just the write answer from you David.
Changing the file names and the routine names solved it.
Thank you very much.
David Fanning wrote:
> Karthikayan Balakrishnan writes:
>
>> I looked at the previous posts where people had similar
>> problems like I do now: how do you compile a programme within
>> another.
>
> You don't. Or rather, this is NOT something you need
> to ever worry about in IDL *if* you name your programs
> properly:
>
> http://www.dfanning.com/tips/namefiles.html
>
>> Then tried David's method (from an earlier post)
>> PRO make_roi_make
>> Resolve_Routine, 'backproject.pro'
>> Resolve_Routine, 'display_resize.pro'
>> Resolve_Routine, 'FileMenu.pro'
>> Resolve_Routine, 'forward_project.pro'
>> Resolve_Routine, 'interactivedraw.pro'
>> Resolve_Routine, 'make_roi.pro'
>> Resolve_Routine, 'plot_tac.pro'
>> Resolve_Routine, 'project1.pro'
>> Resolve_Routine, 'ReconKernel.pro'
>> Resolve_Routine, 'refresh.pro'
>> Resolve_Routine, 'ROI_Cleanup.pro'
>> Resolve_Routine, 'SaveTAC.pro'
>> Resolve_Routine, 'Set_Frame.pro'
>> Resolve_Routine, 'Set_Slice.pro'
>> Resolve_All
>> Save, /Routines, File='roi.sav'
>> END
>
> Uh, must have been somebody else. I'm pretty sure I've
> *never* advocated this! :-)
>
> Cheers,
>
> David
>
> P.S. Let's just say that I discovered more proof this
> week (as if any were needed) that lousy naming conventions,
> combined with code from the GUI Builder, can just about
> make IDL code impenetrable. How people expect this stuff
> to work is really beyond me. :-(
>
|
|
|
Re: Compiling programmes within programmes. [message #36577 is a reply to message #36575] |
Wed, 08 October 2003 14:22  |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
Karthikayan Balakrishnan writes:
> I looked at the previous posts where people had similar
> problems like I do now: how do you compile a programme within
> another.
You don't. Or rather, this is NOT something you need
to ever worry about in IDL *if* you name your programs
properly:
http://www.dfanning.com/tips/namefiles.html
> Then tried David's method (from an earlier post)
> PRO make_roi_make
> Resolve_Routine, 'backproject.pro'
> Resolve_Routine, 'display_resize.pro'
> Resolve_Routine, 'FileMenu.pro'
> Resolve_Routine, 'forward_project.pro'
> Resolve_Routine, 'interactivedraw.pro'
> Resolve_Routine, 'make_roi.pro'
> Resolve_Routine, 'plot_tac.pro'
> Resolve_Routine, 'project1.pro'
> Resolve_Routine, 'ReconKernel.pro'
> Resolve_Routine, 'refresh.pro'
> Resolve_Routine, 'ROI_Cleanup.pro'
> Resolve_Routine, 'SaveTAC.pro'
> Resolve_Routine, 'Set_Frame.pro'
> Resolve_Routine, 'Set_Slice.pro'
> Resolve_All
> Save, /Routines, File='roi.sav'
> END
Uh, must have been somebody else. I'm pretty sure I've
*never* advocated this! :-)
Cheers,
David
P.S. Let's just say that I discovered more proof this
week (as if any were needed) that lousy naming conventions,
combined with code from the GUI Builder, can just about
make IDL code impenetrable. How people expect this stuff
to work is really beyond me. :-(
--
David W. Fanning, Ph.D.
Fanning Software Consulting, Inc.
Phone: 970-221-0438, E-mail: david@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
|
|
|