October 11, 2017

What is Robotic Process Automation (RPA)?

Filed under: General — Marcus Tettmar @ 2:32 pm

Our longstanding customers will know we’ve never really been into jargon here at MJT. Jargon in the IT industry tends to come and go. And there’s something quite amusing about a term that pops up and is touted as being some amazing new thing when it simply describes something we’ve been doing here at MJT Net Ltd for 20 years! On the other hand any term that helps to describe what we do is useful and I suppose it’s nice to know that finally, after all this time, what we do in our little niche of the IT world now has a name: Robotic Process Automation or RPA.

So those of you who have been using Macro Scheduler for a while know what RPA is, even if you’ve never called it that.

Robotic Process Automation tools allow you to create “bots” (we’ve always called them macros) to automate business processes (often by simulating a user). With RPA we automate repetitive tasks – taking the robot out of the human – freeing people up for more value-adding activities.

Our customers have been automating their processes robotically for years, ever since Macro Scheduler was first released way back in 1997.

August 11, 2017

Morning Rant

Filed under: General — Marcus Tettmar @ 10:13 am

A customer filing PayPal disputes rather than emailing us and then, despite confirming that they have the software, failing to cancel the dispute and PayPal finding in their favour, leaving us out of pocket!

PayPal is costly and causes so many accounting headaches it isn’t true. I’ve a good mind to remove it from our site. How many people only buy because we accept PayPal? Anyone?

Another “customer” asking us to write a script, watching us write code, seeing it working, speaking favourably throughout the project at every step, never voicing any concern and then refusing to pay at the end. What’s the answer, lawyers and contracts, which would mean we’d have to put the prices up, or just stop offering script development services? Answers below.

Maybe give up completely. It isn’t what it used to be. This was fun in the early Internet days. Now it just feels like everyone wants something for nothing. Convince me otherwise below.

February 6, 2017

Our 20th Year!

Filed under: Announcements,General — Marcus Tettmar @ 5:39 pm

Happy New Year! A somewhat belated new year greeting, but one that comes with the realisation that this year marks the 20th year of Macro Scheduler. The first version was released way back in 1997!

20 years! Quite amazing. It all happened by accident really and I certainly didn’t expect it to still be going strong 20 years later. In fact it’s stronger than ever.

Thanks so much to all of our customers for all your support and feedback, helping to make Macro Scheduler the product it is. Some of you have been around since that very first year and still use the software today, and that makes me very proud.

Here’s to another 20 years!

January 25, 2017

Templates and Default Templates

Filed under: General — Marcus Tettmar @ 11:49 am

Did you know you can create script templates to use when you create new macros in Macro Scheduler?

When you create a new macro you can choose File/New Macro from Template. This allows you to browse for a .scp file to use as a template. There are some pre-built templates in the Templates subfolder of the program folder which by default you will be presented with.

To create your own templates just create a script as normal or use the standalone editor and export it to a name and folder of your choice. You can then use it later with the “New Macro from Template” option.

If you’re always writing the same stuff when you create a new macro – e.g. maybe you have a standard way of documenting your macros with a code block at the top, you might find default templates really useful. You will probably have noticed that “from the factory” Macro Scheduler puts some comments at the top of all new scripts. You can change this or add your own comments/code by creating a default template.

To create a default template create a script file called default.scp and store it in a Templates subfolder beneath your main macro folder (usually My Documents\Macro Scheduler 14). This default template will then be loaded whenever you create a new macro using File/New Macro.

January 12, 2017

Image Recognition Kudos

Filed under: General — Marcus Tettmar @ 12:40 pm

It’s always nice to receive unsolicited praise. I thought I would share this with you which was sent into us from one of our customers, Lee Hightire:

“You have an Incredibly Awesome product! I just used the Image Recognition tool to help me get at an item in the Sys Tray (needed to pause syncing of OneDrive). I was beating my head against the wall trying other methods, and the Image Recognition tool essentially wrote the code (and trust me, I needed it to do so). I just wanted to say thanks.”

September 7, 2016

Toast Notification Window for your Scripts

Filed under: General,Scripting — Marcus Tettmar @ 10:52 am

Over in the forums dtaylor has posted a script library which allows you to show a small notification window in the lower right of your screen. Useful for reporting on progress during your script, in loops etc.

Grab it here.

August 5, 2016

Capture Screen Text using OCR

Filed under: Automation,General,Scripting — Marcus Tettmar @ 3:37 pm

Here’s a way to get screen text from any application – even from an image – using OCR and a free open source tool called Tesseract.

First, you need to download and install Tesseract. You can get it here.

Tesseract is a command line utility. The most basic syntax is:

tesseract.exe input_image_file output_text_file

So you could call it from a Macro Scheduler script something like this:

//Capture screen to bmp file - you could instead capture only a window or use FindObject to get coordinates of a specific object
GetScreenRes>X2,Y2
ScreenCapture>0,0,X2,Y2,%SCRIPT_DIR%\screen.bmp

//run tesseract on the screen grab and output to temporary file
Let>RP_WAIT=1
Let>RP_WINDOWMODE=0
Run>"C:\Program Files (x86)\Tesseract-OCR\tesseract.exe" "%SCRIPT_DIR%\screen.bmp" "%SCRIPT_DIR%\tmp"

//read temporary file into memory and delete it
ReadFile>%SCRIPT_DIR%\tmp.txt,theText
DeleteFile>%SCRIPT_DIR%\tmp.txt

//Display the text in a message box 
MessageModal>theText

This example simply captures the entire screen. You probably wouldn’t normally want to do this. Instead you could capture a specific window:

//Capture just the Notepad Window
SetFocus>Untitled - Notepad
GetWindowPos>Untitled - Notepad,X1,Y1
GetWindowSize>Untitled - Notepad,w,h
ScreenCapture>X1,Y1,{%X1%+%w%},{%Y1%+%h%},%SCRIPT_DIR%\screen.bmp

Or even a specific object:

//capture just the editor portion of notepad ... 
SetFocus>Untitled - Notepad
GetWindowHandle>Untitled - Notepad,hWndParent
FindObject>hWndParent,Edit,,1,hWnd,X1,Y1,X2,Y2,result
ScreenCapture>X1,Y1,X2,Y2,%SCRIPT_DIR%\screen.bmp

Either way you then have a screen bitmap you can pass into Tesseract.

Once you’ve retrieved the text you would probably want to parse it, using e.g. RegEx. Here’s an article on a RegEx expression useful for parsing out data.

August 4, 2016

How to Run an Access Macro from Macro Scheduler

Filed under: Automation,General,Scripting — Marcus Tettmar @ 4:57 pm

Recently someone asked in the forums how to “Automatically Detect MS Office Install Location” so that they could run an Access macro.

Well, there are ways to get the path of an installed Office application, but it isn’t necessary in order to run an Access macro. This is a rehash of my forum answer:

You can run an Access macro via the command line using the /x switch. The ExecuteFile command lets you pass parameters. So you could just do this:

ExecuteFile>%USERDOCUMENTS_DIR%\MyDb.accdb,/x Macro1

This will open the DB and run macro “Macro1”. Note my DB is in my documents folder here so I’m just using USERDOCUMENTRS_DIR but this could be any path.

Here’s a list of other command line switches.

For more control you could use VBScript:

VBSTART
  Sub RunMacro(accessfile,macroname)
    dim accessApp
    set accessApp = createObject("Access.Application")
    accessApp.OpenCurrentDataBase(accessfile)
    'comment next line out if you don't want access to be visible
    accessApp.visible = true
    accessApp.DoCmd.RunMacro macroname
    'you can run a subroutine or function in module code instead if you want:
    'accessApp.run "routinename"
    accessApp.Quit
    set accessApp = nothing
  End Sub
VBEND

VBRun>RunMacro,%USERDOCUMENTS_DIR%\MyDb.accdb,Macro1

This gives you more control – you could make it invisible, and as you can see you could run VBA code instead if you want – or access any of the other methods. Anything you can do inside Access you can do here – by converting VBA to VBScript:

http://help.mjtnet.com/article/19-converting-office-vba-to-vbscript

But if you do really want to get the path, how about querying the mime-type in the registry:

RegistryReadKey>HKEY_CLASSES_ROOT,ms-access\shell\open\command,,accPath
ExtractFilePath>accPath,accPath

Enjoy!

July 25, 2016

Relative Paths for Portable Macros – SCRIPT_DIR and BMP_DIR Explained [Recap]

Filed under: General,Scripting — Marcus Tettmar @ 2:19 pm

Are your macros reading from other files? Find out how to avoid hard coding file paths and use relative folders:

http://help.mjtnet.com/article/167-relative-paths-for-portable-macros-explaining-scriptdir-and-bmpdir

July 20, 2016

What do you want to see in Macro Scheduler?

Filed under: General — Marcus Tettmar @ 10:25 am

What would you like to see added to Macro Scheduler? Comment below.

« Newer PostsOlder Posts »