Automated report scheduling (autoit - scheduled_tasks)

Huysmans
Member Posts: 13
I'm working on automating several aspects of Navision system maintenance. The work is progressing nicely. However I'm having serious trouble getting a navision client started using ScheduledTasks.
In the past we have been using the tools from ExpandIt. These are just not flexible enough. So after some research I discovered AutoIt v3. This nice, well documented scripting language enables me to do anything I want.
So I now have several scripts which can be used to control some batch processing. These all work flawlessly when started from within explorer or a command window. However they won't function when initiated from the ScheduledTasks (Microsoft Windows 2000 [Version 5.00.2195]).
Any one, any idea? I've been struggling to find out what goes wrong but the only thing I can detect is that the Navision client will be started but seems to hang shortly after that. Could this be caused by lack of a controlling tty? (still having difficulty to forget my UNIX background
)
Any suggestions to solve this riddle?
In the past we have been using the tools from ExpandIt. These are just not flexible enough. So after some research I discovered AutoIt v3. This nice, well documented scripting language enables me to do anything I want.
So I now have several scripts which can be used to control some batch processing. These all work flawlessly when started from within explorer or a command window. However they won't function when initiated from the ScheduledTasks (Microsoft Windows 2000 [Version 5.00.2195]).
Any one, any idea? I've been struggling to find out what goes wrong but the only thing I can detect is that the Navision client will be started but seems to hang shortly after that. Could this be caused by lack of a controlling tty? (still having difficulty to forget my UNIX background

Any suggestions to solve this riddle?
0
Comments
-
Usually, these problems are can be contributed to not having enough rights to run the tasks. Create a user with the same rights you have (or use your own account name) and use that account to run the scheduled job...
What you could also use (I use it quite often with AutoIt) is Sanur: it makes it possible to use runas without the need of typing a password. You can download it here: http://www.commandline.co.uk/sanur/0 -
Thanks for your reply. I will certainly take a good look at sanur. This might just be the right solution for some other batch processing issue.
However, I am afraid this isn't the cause of the problem. Like stated in previous mail; the scripts run flawlessly when initiated from commandline or explorer. The user-id I use for scheduled-tasks is the exact same as the one I use to login on the machine and run commandline or explorer.
So as far as I can see, UID's are identical. Further more, the problem is not in getting the navision session up and running but in getting it to terminate after the job is completed.
Still wondering my head off :x0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions