Jump to content

Request for a jump-start on my project requirement - (Moved)


Gorlash
 Share

Recommended Posts

I am new to AutoIt, though I am very experienced in C/C++ programming...

So I'm studying AutoIt, and will continue to do so, but the reason that I am here, today, is because I have a specific problem that I would like to solve.
I am hoping to get some hints on how to solve specific challenges in AutoIt, *without* having to do the six-month general learning curve, because I want to use it Now...  I hope some folks here will be willing to help me!!

Here's my challenge... I'm scanning a book into PDF, using Windows Fax and Scan program...  this task requires the following iterative steps:

(0).  Windows Fax and Scan is already running; my system is Windows 10 Pro
1. click "New Scan" button
    this opens the "Select Device" dialog
2. double-click (or otherwise select) the second scanner in the "Select Device" dialog.
    this opens the "New Scan" dialog
    I have a custom printer profile set up as default in the "New Scan" dialog, so:
3. click the Scan button

rinse and repeat many many times...
I've been clicking these buttons myself for hours recently, but it seems like a perfect job for an automation program...

So, I'm doing some researching into how to write an AutoIt script to iterate on 1-3 above...
Here are my thoughts, and my existing questions:

1. The first thing I have to do, is attach the AutoIt script to my application... Is this what I do??
   WinActivate("Windows Fax and Scan")

2. How do I click a specific button??  ('New Scan', in this case)
    Maybe use WinActivate() with the button label?

3. How do I select an element in the 'New Scan' item list??
One possibility is 'right arrow' followed by {Enter}, which works from the keyboard...
Is there some other method that is more thematic?? 

4. click the Scan button...
Actually, that is the default operation on this page, so I probably can use
Send("{Enter}")
but again, I would rather use something that is more thematic - i.e., something that actually clicks the Scan button,
so that a person reading the code, understands what I am doing...

Any suggestions or thoughts, or example programs that already do this type of task with arbitrarily-selected applications?



 

Link to comment
Share on other sites

If you are an experienced C/C++ programmer you don't need months to read the help file. Basically you need a small range of windows and controls functions like WinExists(), WinWait(), WinWaitActivate(), ControlClick(). ControlSend() and maybe Send(). For all these functions you have basic examples in the help file.

PS: not sure why you post this thread here and not in general help forum

When the words fail... music speaks.

Link to comment
Share on other sites

37 minutes ago, Andreik said:

PS: not sure why you post this thread here and not in general help forum

Ummm... there were a number of subforums to choose from, I didn't know which to use...  This seemed valid, sorry if I chose wrong.

 

Link to comment
Share on other sites

  • Moderators

Moved to the appropriate AutoIt General Help and Support forum, as the Developer General Discussion forum very clearly states:

Quote

General development and scripting discussions.


Do not create AutoIt-related topics here, use the AutoIt General Help and Support or AutoIt Technical Discussion forums.

Moderation Team

Public_Domain.png.2d871819fcb9957cf44f4514551a2935.png Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind

Open spoiler to see my UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...