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

Home » Public Forums » archive » Re: restart a procedure by idl
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
Re: restart a procedure by idl [message #7662] Tue, 17 December 1996 00:00
Robert Moss is currently offline  Robert Moss
Messages: 74
Registered: February 1996
Member
R. Bauer wrote:
>
> Hello,
>
> I am using a program to write an other idl program.
> The new program should be started from the running one.
>
> when i do changes in then new program it should be started again from
> the first program. -- It didn't, it used always the first compiled one.
>
> how can I compile the new program again
>
> or
>
> how can I remove the compiled program from idl's memory
>
> --
> R.Bauer
>
> Institut fuer Stratosphaerische Chemie (ICG-1)
> Forschungszentrum Juelich
> email: R.Bauer@kfa-juelich.de

If you want to recompile the modified code on the fly, the
RESOLVE_ROUTINE procedure is what you are looking for. See the online
help for it.

--
Robert M. Moss, Ph.D. - mossrm@texaco.com - FAX (713)954-6911
------------------------------------------------------------ -----
This does not necessarily reflect the opinions of Texaco Inc.
Re: restart a procedure by idl [message #7672 is a reply to message #7662] Fri, 13 December 1996 00:00 Go to previous message
Phil Williams is currently offline  Phil Williams
Messages: 78
Registered: April 1996
Member
Here's a little code snippet that I think does what you want.

;------------------------------------------
pro test

openw, 1, 'test2.pro'
printf,1, "pro test2"
printf, 1, "print, 'hello, world'"
printf, 1, "end"
close, 1

resolve_routine,'test2'
cmd = 'test2'
ok = execute(cmd)

openw, 1, 'test2.pro'
printf, 1, 'pro test2'
printf, 1, 'print, "Goodbye Cruel World"'
printf, 1, 'end'
close, 1

resolve_routine,'test2'
cmd = 'test2'
ok = execute(cmd)

end
;-----------------------------------------

Running returns the following:

IDL> .com test
% Compiled module: TEST.
IDL> test
% Compiled module: TEST2.
hello, world
% Compiled module: TEST2.
Goodbye Cruel World
IDL>
R. Bauer wrote:
>
> Hello,
>
> I am using a program to write an other idl program.
> The new program should be started from the running one.
>
> when i do changes in then new program it should be started again from
> the first program. -- It didn't, it used always the first compiled one.
>
> how can I compile the new program again
>
> or
>
> how can I remove the compiled program from idl's memory
>
> --
> R.Bauer
>
> Institut fuer Stratosphaerische Chemie (ICG-1)
> Forschungszentrum Juelich
> email: R.Bauer@kfa-juelich.de

--
/*********************************************************** ********/
Phil Williams, Ph.D.
Research Instructor
Children's Hospital Medical Center "One man gathers what
Imaging Research Center another man spills..."
3333 Burnet Ave. -The Grateful Dead
Cincinnati, OH 45229
email: williams@irc.chmcc.org
URL: http://scuttle.chmcc.org/~williams/
/*********************************************************** ********/
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Re: Widget tutorial does not write .pro file
Next Topic: warping a 2D-matrix on 3D model

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

Current Time: Wed Oct 08 15:10:49 PDT 2025

Total time taken to generate the page: 0.00472 seconds