Search found 1346 matches

by Dorian (MJT support)
Thu Sep 14, 2023 6:52 am
Forum: Enhancement Suggestions
Topic: ISO 8601 timestamp
Replies: 4
Views: 34944

Re: ISO 8601 timestamp

Thank you for this. I will make sure to pass it on.
by Dorian (MJT support)
Mon Sep 11, 2023 9:16 pm
Forum: Technical / Scripting
Topic: Accessing Array elements
Replies: 11
Views: 10022

Re: Accessing Array elements

Your commented out method is the correct way. You can't use complex expressions with StringReplace.
by Dorian (MJT support)
Sat Sep 09, 2023 3:06 pm
Forum: Beginners
Topic: Out of memory
Replies: 3
Views: 27684

Re: Out of memory

It would be in there if you've used the Text Capture Wizard. If you haven't used that and have no recollection of using text capture in this script, then the GetTextInit suggestion is on the wrong path. :) You can always use CTRL-F to search your scripts. It's very unlikely to be the length of the s...
by Dorian (MJT support)
Sat Sep 09, 2023 12:09 pm
Forum: Beginners
Topic: Out of memory
Replies: 3
Views: 27684

Re: Out of memory

This raises it's head from time to time and is usually due to the GetTextInit functions. We recommend using the OCR functions instead.
by Dorian (MJT support)
Sat Sep 02, 2023 8:29 am
Forum: Beginners
Topic: If function understanding
Replies: 8
Views: 21907

Re: If function understanding

What you want to do is quite complex for a beginner. You'll need to master and fully understand the techniques linked below before you should even think about putting it all together into something resembling your "end product". Learn and test each stage/element. Make sure you can walk before you tr...
by Dorian (MJT support)
Fri Sep 01, 2023 5:02 pm
Forum: Beginners
Topic: If function understanding
Replies: 8
Views: 21907

Re: If function understanding

You know.... I don't think I've ever used that in the 25 years I've been using MS (IfNot probably hasn't existed for 25 years)...

In fact it slipped my mind that it even existed.
by Dorian (MJT support)
Fri Sep 01, 2023 12:51 pm
Forum: Beginners
Topic: If function understanding
Replies: 8
Views: 21907

Re: If function understanding

To compare two variables and exit the script if they are not the same, you'd do something like this :

Code: Select all

if>%variable1%<>%variable2%
  exit
endif
You can see an in-depth description of IF here.
by Dorian (MJT support)
Tue Aug 22, 2023 3:47 pm
Forum: Technical / Scripting
Topic: how to boilerplate macros
Replies: 5
Views: 6559

Re: how to boilerplate macros

You have the OnEvent in an endless loop which doesn't seem like a good idea as you only need that to run once. It didn't work for me either so I changed it so it will look for ., then move on to look for the h, then the i. tbh this approach doesn't make much sense to me as I have a feeling it could ...
by Dorian (MJT support)
Tue Aug 22, 2023 10:07 am
Forum: Technical / Scripting
Topic: how to boilerplate macros
Replies: 5
Views: 6559

Re: how to boilerplate macros

I hope I'm understanding correctly. I think it would be difficult to cover all eventualities, but maybe something like this with all your commonly typed sentences. These are the kind of script that tend to grow in time... ..and of course you could even write it to present a different set of options ...
by Dorian (MJT support)
Mon Aug 21, 2023 7:19 pm
Forum: Technical / Scripting
Topic: select todays dated image
Replies: 3
Views: 5456

Re: select todays dated image

If you want to start with 08/21/2023 and end up with 08212023.jpg, you can simply use StringReplace to replace the "/" with "nothing", then add the path and .jpg to the result. //Get the date GetDate>TheDate //Replace the / StringReplace>TheDate,/,,TheDate //Set the path to your file Let>FilePath=c:...
by Dorian (MJT support)
Mon Aug 14, 2023 10:40 pm
Forum: Technical / Scripting
Topic: Let + MouseMove
Replies: 1
Views: 4796

Re: Let + MouseMove

Either of these would work for photo : Let>photoX=-1100 Let>photoY=662 MouseMove>%photoX%,%photoY% Let>photo=-1100,662 Separate>photo,comma,coord MouseMove>coord_1,coord_2 Date is giving you the error because instead of moving to X and Y coordinates, you're attempting to move to "8/14/2023" which is...
by Dorian (MJT support)
Sun Aug 13, 2023 6:14 pm
Forum: Technical / Scripting
Topic: how to conditionally modify a programs hotkey behavior
Replies: 8
Views: 6743

Re: how to conditionally modify a programs hotkey behavior

Without the loop the script isn't running. It will start and immediately reach the end. Step through it line by line and you'll see.
by Dorian (MJT support)
Sun Aug 13, 2023 3:10 pm
Forum: Technical / Scripting
Topic: how to conditionally modify a programs hotkey behavior
Replies: 8
Views: 6743

Re: how to conditionally modify a programs hotkey behavior

Code: Select all

//wait for F2 press
OnEvent>KEY_DOWN,VK113,0,ClickOK

label>start
wait>0.1
goto>start

//send ctrl-o to dialogue window
SRT>ClickOK
  MessageModal>F2 pressed
  //Press CTRL
  //send>o
  //Release CTRL
END>ClickOK
cron
Sign up to our newsletter for free automation tips, tricks & discounts