×
INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

Contact US

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

windows task automation

windows task automation

windows task automation

(OP)
hi, i wish to know if fortran can help in windows automation.
the job expected is: fortran code (in exe) should invoke a third party software on windows10(call the 3rd party software as ABC). the input file for ABC is a text file, upon the completion of run, the fortran exe should read through the output file (text) of ABC, search for a particular value, exe does some calculations( sort of criteria check). based on it, the input file of ABC is edited again and ABC is run by the fortran exe code - upon completion, again criteria check is done. if condition is met, the program stops, else, the input file is edited and rerun - process continues till the criteria is met.. all this happens automatically after the first run is initiated. my colleagues use perl for such work, is there a way to avoid a new programming language

thanks

RE: windows task automation

You can use a mix of fortran and windows batch or everything in vbscript/javascript. If you use vbscript or javascript, there is no need to install anything since they are part of windows.

RE: windows task automation

(OP)
hi xwb, i dont know any programmng lang other than fortran, so i wish to know if i can survive with fortran for my requirement.

RE: windows task automation


While it may be possible to do what you want with Fortran, it is not necessarily the best tool for the job. What you describe seem to be more of a job for a shell kind of environment (bash, batch) or, yes, one of those versatile scripting languages like Perl, or even better...Python winky smile

New year is coming up, may I suggest a new year resolution? Learn Python...it is easy and very, very, very useful for many things; additionally, it is becoming the scripting language for other programs open-source and commercial alike.






RE: windows task automation

If you are in a windows environment, and you don't wish to install anything, learn javascript/windows batch. It may be outside your comfort zone but you can do quite useful stuff with it.

If you are in a Linux environment, python and bash would be the way to go. It is a lot easier than perl - perl written by a Cobol programmer looks completely different from perl by a C programmer, which again looks completely different from perl by a bash programmer. At least python looks the same, whoever writes it.

You can use python in a windows environment but it will need installing. This may be a problem if you are developing on one machine and running on a different one. Javascript/Windows batch will work on any version of Windows from 95 upwards.

RE: windows task automation

(OP)
gsal/xwb, thanks for the suggestions.. i am working on windows env... whats your take on learning AUTOIT for my requirement.

RE: windows task automation

Autoit is similar to vbscript but with more features. You will still need to install it on other machines. I have only used it twice and that was for automating tests by imitating what users type. It should be able to do what you wish.

RE: windows task automation

(OP)
Hi, i wish to know if fortran has the following capabilities. refer to the below link about perl . in that case, i dont need to use AUTOIT - fortran will serve my purpose.
https://www.perl.com/pub/2005/08/11/win32guitest.h...

RE: windows task automation

GUI features aren't standard Fortran - it depends a lot on which GUI you are using.

For instance, if you are using Intel IVF or CVF or DEC Fortran or some descendant of MS Power Fortran 4, you can use events to transmit key strokes, wheel scrolls etc. Note that this is the old Win32 SDK - not the fancy .net stuff. There are tools to do all sorts of things (have a look at spy.exe, which comes with the std MS distribution). Having said that, you'd have a problem finding someone to maintain it once you leave the company: there aren't that many people out there who know how to program the windows SDK in Fortran. The last place I worked at that used Fortran (site had 2500 employees, 15-20% software engineers), it was only me. Most of them are C/C++ programmers who don't seem to understand something as simple as Fortran and they are getting rarer as .net and C# take over the windows GUI systems.

If you are using Silverfrost, there is a very limited GUI capability. It cannot do automated clicks, button pushes or find window handles

If you are using gfortran, I've got no idea - interfacing gfortran with anything microsoft is a nightmare that you don't want. Some of the gfortran parameters are position dependant. If you are using a C interface, make sure your compiler is at least 2003 or 2008 compatible.

Some gui systems like FLTK use a different system. Their handles aren't the same as Win32 handles.

If it is an X-windows or GTK port, it may be possible. I have used automated clicking and looking for dialogs on X-windows but not GTK. If it is X-windows/Moitf, it is a pretty ancient system.

I don't know about winteracter, forge or dislin.

RE: windows task automation

As other folks suggested, you could use both Windows Batch script and Fortran executable to fulfill your goal without learning a new programming language. However, if it is a long-term-supported project, I would recommend getting to learn a new scripting language such as Python, Perl, which is able to better maintain and scale up your project.

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members! Already a Member? Login


Resources

Low-Volume Rapid Injection Molding With 3D Printed Molds
Learn methods and guidelines for using stereolithography (SLA) 3D printed molds in the injection molding process to lower costs and lead time. Discover how this hybrid manufacturing process enables on-demand mold fabrication to quickly produce small batches of thermoplastic parts. Download Now
Design for Additive Manufacturing (DfAM)
Examine how the principles of DfAM upend many of the long-standing rules around manufacturability - allowing engineers and designers to place a part’s function at the center of their design considerations. Download Now
Taking Control of Engineering Documents
This ebook covers tips for creating and managing workflows, security best practices and protection of intellectual property, Cloud vs. on-premise software solutions, CAD file management, compliance, and more. Download Now

Close Box

Join Eng-Tips® Today!

Join your peers on the Internet's largest technical engineering professional community.
It's easy to join and it's free.

Here's Why Members Love Eng-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close