Search found 640 matches

by Dorian (MJT support)
Thu Jul 02, 2020 1:23 pm
Forum: Beginners
Topic: Can't open a dialog box
Replies: 5
Views: 61

Re: Can't open a dialog box

kmarlowe wrote:
Thu Jul 02, 2020 12:26 pm
Why does the variable strline not need % in the ReadLn, but needs them in the Message?
This article in the KB will explain that : Using Variables and When to use Percent Symbols (%variable%)
by Dorian (MJT support)
Tue Jun 30, 2020 8:33 pm
Forum: Beginners
Topic: Can't open a dialog box
Replies: 5
Views: 61

Re: Can't open a dialog box

Show displays a dialog created with a Dialog block

What you're looking for is something like :

Code: Select all

ReadLn>C:\temp\validpings.txt,1,strLine
Message>Hi,%strLine%
or

Code: Select all

ReadLn>C:\temp\validpings.txt,1,strLine
MessageModal>Hi,%strLine%
by Dorian (MJT support)
Sun Jun 28, 2020 5:59 pm
Forum: Beginners
Topic: Selecting the closest image match to another image match
Replies: 1
Views: 31

Re: Selecting the closest image match to another image match

I'm not sure I understand what you're trying to do, but if your script is finding something it shouldn't (false positives), then maybe try increasing your tolerance from 0.7 to 0.8 or 0.9 and see if it makes a difference. In the meantime, I think you need help with your Repeat/Until loops. Yours is ...
by Dorian (MJT support)
Sun Jun 28, 2020 5:49 pm
Forum: Beginners
Topic: multiple images Error
Replies: 3
Views: 50

Re: multiple images Error

Always happy to help.
by Dorian (MJT support)
Sat Jun 27, 2020 5:40 pm
Forum: Beginners
Topic: multiple images Error
Replies: 3
Views: 50

Re: multiple images Error

My guess is you're trying to do something like this.. Note how I use "Else" differently.. //If lvl25 base is found, click on it, if not, click on purple. SetFocus>Screen One Srt>Bases FindImagePos>C:\Users\KiKAS\Desktop\pics for last shelter\Adcanced\LvL 25 base.bmp,SCREEN,0.7,1,XArr,YArr,NumFound,C...
by Dorian (MJT support)
Wed Jun 24, 2020 9:33 am
Forum: Beginners
Topic: same image different locations
Replies: 5
Views: 121

Re: same image different locations

Let>kk=C:\Users\KiKAS\Desktop\pics for last shelter\Adcanced\Recomended Donation.bmp ...would work. Like this : Let>kk=C:\Users\KiKAS\Desktop\pics for last shelter\Adcanced\Recomended Donation.bmp FindImagePos>%kk%,WINDOW:Screen One,0.7,1,XArr,YArr,NumFound,CCOEFF If If you're simply trying to clic...
by Dorian (MJT support)
Tue Jun 23, 2020 11:34 am
Forum: Beginners
Topic: same image different locations
Replies: 5
Views: 121

Re: same image different locations

Maybe you don't have to count at all. I notice on the 22/25 image you have a timer (00:19:54) at the bottom - does that disappear when you've completed all 25? If so, and if the ":" is always in the exact same position, can you monitor that pixel colour so the script clicks the button if the : is th...
by Dorian (MJT support)
Tue Jun 23, 2020 8:53 am
Forum: Beginners
Topic: same image different locations
Replies: 5
Views: 121

Re: same image different locations

Are you able to provide screenshots and more detailed explanations so that we might be able to understand more clearly?
by Dorian (MJT support)
Thu Jun 18, 2020 9:54 am
Forum: Technical / Scripting
Topic: Why Run> doesn't work like Start, Run?
Replies: 4
Views: 166

Re: Why Run> doesn't work like Start, Run?

Here you go. I usually use /C when I want the window to close afterwards, and /K if I want it to stay open. This is useful if things aren't going as expected. Microsoft Windows XP [Version 5.1.2600] (C) Copyright 1985-2001 Microsoft Corp. C:\>cmd /? Starts a new instance of the Windows XP command in...
by Dorian (MJT support)
Wed Jun 17, 2020 12:19 pm
Forum: Technical / Scripting
Topic: Macro mouse
Replies: 1
Views: 66

Re: Macro mouse

Wait time can be as low as 1 millisecond : Timer>start Wait>0.001 Timer>end Let>milliseconds=end-start MessageModal>Milliseconds elapsed: %milliseconds% *Naturally you'll get a different result each time you run it as this is entirely dependent on what the system is doing because of course this is m...
by Dorian (MJT support)
Wed Jun 17, 2020 12:01 pm
Forum: Technical / Scripting
Topic: Why Run> doesn't work like Start, Run?
Replies: 4
Views: 166

Re: Why Run> doesn't work like Start, Run?

The problem isn't RunProgram, it's the strFFmpeg you're creating. There's a few things missing. Let's get back to basics. Here's an example of some working RunProgram ffmpeg code which creates a 3 second clip. RunProgram>CMD /c c:\ffmpeg\bin\ffmpeg.exe -ss 00:00:0 -i c:\ffmpeg\bin\fs18.mp4 -t 00:00:...
by Dorian (MJT support)
Mon Jun 15, 2020 9:40 am
Forum: Technical / Scripting
Topic: How to repeat this code until there is no more same image
Replies: 1
Views: 66

Re: How to repeat this code until there is no more same image

You can do that with While / EndWhile , so the code will keep looping until a certain condition is met. If the image is visible and found by FindImagePos, NumFound will be 1. So we can keep looping until it is no longer 1. Note that we set NumFound to 1 before the While/Endwhile loop to ensure the c...
by Dorian (MJT support)
Thu Jun 11, 2020 5:19 pm
Forum: Technical / Scripting
Topic: FindImagePos not staying within the WINDOW given
Replies: 1
Views: 82

Re: FindImagePos not staying within the WINDOW given

If it doesn't find the window it searches the entire screen. I'm wondering if it could be one of these : 1: The window is not visible, cannot be captured and so you're getting a false positive. Try setting focus. 2: The window you're getting a false positive in is on top of the one you want. 3: The ...
by Dorian (MJT support)
Wed Jun 03, 2020 10:00 am
Forum: Scripts and Tips
Topic: Combining scripts
Replies: 1
Views: 172

Re: Combining scripts

I think there could be a few things at play here. Yes, you may not be releasing your modifier keys with Release . That link also shows you which keys can or should be released. A good indication of this is if any text sent has it's case reversed. Shift is still pressed. So make sure each relevant Pr...
by Dorian (MJT support)
Fri May 15, 2020 9:09 am
Forum: Technical / Scripting
Topic: I'm new and I need a little help...
Replies: 3
Views: 272

Re: I'm new and I need a little help...

Always happy to help, and thank you for your kind comments.
Sign up to our newsletter for free automation tips, tricks & discounts