Search found 883 matches

by Dorian (MJT support)
Sun Mar 07, 2021 7:21 pm
Forum: Technical / Scripting
Topic: Help clicking a webpage button
Replies: 8
Views: 210

Re: Help clicking a webpage button

I'd have thought either of these would work : IECreate>IE_Inst IENavigate>IE_Inst,https://ifttt.com/applets/SAMPLEID,res IETagEventByAttrib>https://ifttt.com/applets/SAMPLEID,A,classname=btn-sm btn-outlined btn,click, IETagEventByAttrib>https://ifttt.com/applets/SAMPLEID,A,innertext=Check now,click,
by Dorian (MJT support)
Sat Mar 06, 2021 5:51 pm
Forum: Beginners
Topic: ListBox dialog control - how to loop and count
Replies: 12
Views: 264

Re: ListBox dialog control - how to loop and count

Just write it to Excel instead. Something like this should get you started. Dialog>Dialog1 object Dialog1: TForm Left = 2322 Top = 431 HelpContext = 5000 BorderIcons = [biSystemMenu] Caption = 'CustomDialog' ClientHeight = 428 ClientWidth = 1170 Color = clBtnFace Font.Charset = DEFAULT_CHARSET Font....
by Dorian (MJT support)
Sat Mar 06, 2021 4:03 pm
Forum: Beginners
Topic: ListBox dialog control - how to loop and count
Replies: 12
Views: 264

Re: ListBox dialog control - how to loop and count

Like this : GetDialogProperty>Dialog1,MSListBox1,Text,TheText That gets all the contents. You can then use Separate on the result, if you wish. In the case of the sample below, we could separate by CRLF Dialog>Dialog1 object Dialog1: TForm Left = 2322 Top = 431 HelpContext = 5000 BorderIcons = [biSy...
by Dorian (MJT support)
Wed Mar 03, 2021 6:08 pm
Forum: Technical / Scripting
Topic: Image Recognition Wizard
Replies: 2
Views: 76

Re: Image Recognition Wizard

They do actually do different things. Middle right would be on the right edge, whereas "To the Right" is off the edge. When choosing "to the right" you'll see you can then set how many pixels to offset it to the right. Below you can see the code generated when selecting "middle right", and then "to ...
by Dorian (MJT support)
Wed Mar 03, 2021 3:06 pm
Forum: Technical / Scripting
Topic: Add> and Sub> doesn't allow for dynamic variables
Replies: 3
Views: 96

Re: Add> and Sub> doesn't allow for dynamic variables

I think that's personal preference. It's been kept in for the sake of backward compatibility, but as you've discovered there may be times where it isn't suitable.
by Dorian (MJT support)
Wed Mar 03, 2021 12:31 pm
Forum: Technical / Scripting
Topic: Add> and Sub> doesn't allow for dynamic variables
Replies: 3
Views: 96

Re: Add> and Sub> doesn't allow for dynamic variables

Add was deprecated by Let for numeric calculations. It seems to do what you're expecting if you use Let instead.

Code: Select all

Let>var_1=0
Let>var_2=0
Let>var_3=0
Let>k=0
Repeat>k
  Let>k=k+1
  Let>var_%k%=var_%k%+1
  //Sub>var_%k%,1
Until>k=3
by Dorian (MJT support)
Tue Mar 02, 2021 11:13 am
Forum: Technical / Scripting
Topic: Excel Add-in not working when MS opens Excel
Replies: 2
Views: 99

Re: Excel Add-in not working when MS opens Excel

Although I can't explain why the add-on might not be loading, I can suggest a workaround. What happens if you use ExecuteFile to launch Excel? Does the add-on load? Then you can use XLGet (added Version 14.4 04/10/2017) to assign the book handle, and continue as normal. executefile>d:\hours.xlsx wai...
by Dorian (MJT support)
Mon Mar 01, 2021 10:08 pm
Forum: Technical / Scripting
Topic: Scan Line Index Out of Range
Replies: 5
Views: 162

Re: Scan Line Index Out of Range

I'll mention it to dev.
by Dorian (MJT support)
Mon Mar 01, 2021 8:04 pm
Forum: Technical / Scripting
Topic: Scan Line Index Out of Range
Replies: 5
Views: 162

Re: Scan Line Index Out of Range

WaitRectChanged hasn't been updated for many years - not many people use it so that's probably why it's slipped the net when it comes to multi-monitor setups.
by Dorian (MJT support)
Mon Mar 01, 2021 8:00 pm
Forum: Technical / Scripting
Topic: ChromeFindElements error
Replies: 7
Views: 162

Re: ChromeFindElements error

Apologies, that was my internal link. I have edited it now. This is the one you need.
by Dorian (MJT support)
Mon Mar 01, 2021 7:18 pm
Forum: Technical / Scripting
Topic: ListBox dialog control
Replies: 12
Views: 247

Re: ListBox dialog control

Here's something from scratch that I think is the beginning of what you want to do. It should demonstrate a basic principle and allow you to build from there. Build your strings within the PopulateList subroutine, then set the dialog property to display your strings at the end of the subroutine. Dia...
by Dorian (MJT support)
Mon Mar 01, 2021 6:57 pm
Forum: Technical / Scripting
Topic: ChromeFindElements error
Replies: 7
Views: 162

Re: ChromeFindElements error

This article should help.

Then see if you can just run this very simple code.

Code: Select all

let>TheURL=https://www.mjtnet.com
Let>CHROMEDRIVER_EXE=c:\chromedriver.exe
ChromeStart>session_id
ChromeNavigate>session_id,url,%TheURL%
by Dorian (MJT support)
Mon Mar 01, 2021 5:31 pm
Forum: Technical / Scripting
Topic: ListBox dialog control
Replies: 12
Views: 247

Re: ListBox dialog control

I'm still trying to understand, maybe we now have too much information. Are you able to describe a simple principle for what you're wishing to do? Can we go back to basics and forget the 700+ line example and work with something simple so we can demonstrate a principle? Apologies if I am being slow.
by Dorian (MJT support)
Mon Mar 01, 2021 3:06 pm
Forum: Technical / Scripting
Topic: ListBox dialog control
Replies: 12
Views: 247

Re: ListBox dialog control

I'm not sure I follow. Could you explain more please? Do you want it to start off with this.. Scénario 1 : Homme 30 ....50000 Scénario 2 : Homme 40 ....100000 Scénario 3 : Homme 50 ...250000 ..and then change to this? Scénario 1 : Homme 30 ....50000 Scénario 2 : Homme 30 ....100000 Scénario 3 : Homm...
by Dorian (MJT support)
Mon Mar 01, 2021 1:22 pm
Forum: Scripts and Tips
Topic: Get Next Sunday | Get Last Weekday
Replies: 0
Views: 253

Get Next Sunday | Get Last Weekday

Recently over at support we'd had a couple of questions asking how to figured out when the last weekday was, and when the next Sunday is. I thought these examples may help : Get Next Sunday . Using DayofWeek , Sunday is day 1, Monday is day 2, and so on. All we need to do is get today and subtract i...
Sign up to our newsletter for free automation tips, tricks & discounts