Re: workbench filenames and program names [message #58488] |
Wed, 30 January 2008 16:52 |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
elwood writes:
> Often my students write a program called for tutorial1 example:
> pro tutorial1
>
> but the filename in which the program resides might be tut1.pro
Don't let your students do this. If you teach them only
one thing, teach them to name their files correctly.
Like typing, they will use this every day of their
working lives. It will be the most important lesson
they learn. :-)
http://www.dfanning.com/tips/namefiles.html
Cheers,
David
--
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.")
|
|
|
Re: workbench filenames and program names [message #58493 is a reply to message #58488] |
Wed, 30 January 2008 14:26  |
Vince Hradil
Messages: 574 Registered: December 1999
|
Senior Member |
|
|
On Jan 30, 2:32 pm, elwood <epolo...@uwsp.edu> wrote:
> Probly a pretty remedial question----
>
> Often my students write a program called for tutorial1 example:
> pro tutorial1
>
> but the filename in which the program resides might be tut1.pro
>
> they can compile tut1.pro
> but when they use the workbench to RUN the program it trys to run
> a program called tut1, which of course doesnt exist.
> The program is called tutorial1
>
> Is there a way to tell workbench to run the actual program name rather
> than the filename?
> or do they need to use the commandline?
>
> I looked around on the help pages, but didnt see a quick answer to
> this question,
> I'll keep looking.
>
> Thx,
> Elisha
If it is in a project by itself, you can change the properties of the
project to run tutoriall.
Project->Properties->IDL Project Properties->Run Command
|
|
|
Re: workbench filenames and program names [message #58495 is a reply to message #58493] |
Wed, 30 January 2008 12:52  |
Jean H.
Messages: 472 Registered: July 2006
|
Senior Member |
|
|
elwood wrote:
>
> Probly a pretty remedial question----
>
> Often my students write a program called for tutorial1 example:
> pro tutorial1
>
> but the filename in which the program resides might be tut1.pro
>
> they can compile tut1.pro
> but when they use the workbench to RUN the program it trys to run
> a program called tut1, which of course doesnt exist.
> The program is called tutorial1
>
> Is there a way to tell workbench to run the actual program name rather
> than the filename?
> or do they need to use the commandline?
>
> I looked around on the help pages, but didnt see a quick answer to
> this question,
> I'll keep looking.
>
> Thx,
> Elisha
the proper way would be to have a program named as the filename.
Now, in your case, you can
1) compile the file and type "tutorial1" in the command line
or 2) write a small procedure called "tut1" that calls "tutorial1". Make
sure that this procedure is the last one in your file (at the bottom of
the file)
Jean
|
|
|