Re: binary sub? [message #35297] |
Tue, 03 June 2003 08:25 |
R.Bauer
Messages: 1424 Registered: November 1998
|
Senior Member |
|
|
Tomson wrote:
> Thank you all. For example,
> I use .compile
> .resolve_all
> .save,/all,file='c:\rsi\idl54\lib\sub.sav'
> to creat sav file name sub.sav in the IDL default path.
save,/routines !!!
Reimar
>
> pro testsav
> sub,a,b
> print,a+b
> end
>
> But when I run testsave, there is a message 'attempt to call undifined
> proceedure/function SUB'. What's wrong?
>
>
>
>
>
--
Reimar Bauer
Institut fuer Stratosphaerische Chemie (ICG-I)
Forschungszentrum Juelich
email: R.Bauer@fz-juelich.de
------------------------------------------------------------ -------
a IDL library at ForschungsZentrum Juelich
http://www.fz-juelich.de/icg/icg-i/idl_icglib/idl_lib_intro. html
============================================================ =======
|
|
|
Re: binary sub? [message #35298 is a reply to message #35297] |
Tue, 03 June 2003 06:06  |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
Tomson (tom2959@21cn.com) writes:
> But when I run testsave, there is a message 'attempt to call undifined
> proceedure/function SUB'. What's wrong?
You forgot to set the ROUTINES keyword on the SAVE command.
You are saving variables, rather than compiled routines.
Here is an article on how to create stand-alone (well,
as stand-alone as IDL will allow) IDL applications.
http://www.dfanning.com/tips/idl_icon.html
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: binary sub? [message #35300 is a reply to message #35298] |
Tue, 03 June 2003 00:23  |
tomson
Messages: 39 Registered: March 2003
|
Member |
|
|
Thank you all. For example,
I use .compile SUB
.resolve_all
.save,/all,file='c:\rsi\idl54\lib\sub.sav'
to creat sav file name sub.sav in the IDL default path.
pro testsav
sub,a,b
print,a+b
end
But when I run testsave, there is a message 'attempt to call undifined
proceedure/function SUB'. What's wrong?
|
|
|
Re: binary sub? [message #35301 is a reply to message #35300] |
Tue, 03 June 2003 00:23  |
tomson
Messages: 39 Registered: March 2003
|
Member |
|
|
Thank you all. For example,
I use .compile SUB
.resolve_all
.save,/all,file='c:\rsi\idl54\lib\sub.sav'
to creat sav file name sub.sav in the IDL default path.
pro testsav
sub,a,b
print,a+b
end
But when I run testsave, there is a message 'attempt to call undifined
proceedure/function SUB'. What's wrong?
|
|
|
Re: binary sub? [message #35302 is a reply to message #35301] |
Tue, 03 June 2003 00:18  |
tomson
Messages: 39 Registered: March 2003
|
Member |
|
|
Thank you all. For example,
I use .compile SUB
.resolve_all
.save,/all,file='c:\rsi\idl54\lib\sub.sav'
to creat sav file name sub.sav in the IDL default path.
pro testsav
sub,a,b
print,a+b
end
But when I run testsave, there is a message 'attempt to call undifined
proceedure/function SUB'. What's wrong?
|
|
|
Re: binary sub? [message #35303 is a reply to message #35302] |
Tue, 03 June 2003 00:17  |
tomson
Messages: 39 Registered: March 2003
|
Member |
|
|
Thank you all. For example,
I use .compile
.resolve_all
.save,/all,file='c:\rsi\idl54\lib\sub.sav'
to creat sav file name sub.sav in the IDL default path.
pro testsav
sub,a,b
print,a+b
end
But when I run testsave, there is a message 'attempt to call undifined
proceedure/function SUB'. What's wrong?
|
|
|
Re: binary sub? [message #35304 is a reply to message #35303] |
Tue, 03 June 2003 00:15  |
tomson
Messages: 39 Registered: March 2003
|
Member |
|
|
Thank you all. For example,
I use .compile
.resolve_all
.save,/all,file='c:\rsi\idl54\lib\sub.sav'
to creat sav file name sub.sav in the IDL default path.
pro testsav
sub,a,b
print,a+b
end
But when I run testsave, there is a message 'attempt to call undifined
proceedure/function SUB'. What's wrong?
|
|
|
Re: binary sub? [message #35305 is a reply to message #35304] |
Tue, 03 June 2003 00:13  |
tomson
Messages: 39 Registered: March 2003
|
Member |
|
|
Thank you all. For example,
I use .compile
.resolve_all
.save,/all,file='c:\rsi\idl54\lib\sub.sav'
to creat sav file name sub.sav in the IDL default path.
pro testsav
sub,a,b
print,a+b
end
But when I run testsave, there is a message 'attempt to call undifined
proceedure/function SUB'. What's wrong?
|
|
|
Re: binary sub? [message #35306 is a reply to message #35305] |
Mon, 02 June 2003 16:28  |
Rick Towler
Messages: 821 Registered: August 1998
|
Senior Member |
|
|
"Tomson" wrote in message...
> Some of IDL programs are in binary form. Can I compile my subroutine to
> binary file which can be called from other program? How to do that?
As usual, David Fanning has a nice tip on this. Hummmm, wait a minute.
Maybe not. He does have this morsel:
http://www.dfanning.com/ographics_tips/rt_objects.html
But I thought there was a more thorough explanation. I suggest searching
the archives via google groups for something like "compiling run time .sav"
> I think they must run fast.
I wish they did, but they don't.
-Rick
|
|
|
|