Asked — Edited

Smart Arrange Automatically?

Is there a way to programmatically have ARC run "Smart Arrange" via a script rather than going to the Control tab and manually clicking it? My controls always auto load off screen and only "Smart Arrange" fixes the issue.


ARC Pro

Upgrade to ARC Pro

ARC Pro is more than a tool; it's a creative playground for robot enthusiasts, where you can turn your wildest ideas into reality.

#1  

You could use the "remote mouse" plugin to do the mouse movement and clicks for you via a script.

Alan

#2  

Totally did not consider that. Thank you! I honestly didn't have a use for that plug in until now. That's pretty darn handy.

I implemented it like this, in my Int script which is set to run from the shortcut created in ARC for my project, I run the "SmartArrange" script. It used the mouse location data to hover over Control tab, left click, hover over Smart Arrange, left click, hover over File tab, left click, hover over 2nd desktop window, left click, hover over Control tab, left click, hover over Smart Arrange, left click, hover over File tab, left click, hover over 1st desktop window, left click.

I have to "Smart Arrange" for the 1st and 2nd desktop, after than I'm good. Only took a couple of minutes to implement! :)

Thanks again Alan!


ControlCommand("Remote Mouse", SetAbsolute, 229, 36)#Control tab
sleep(200)
ControlCommand("Remote Mouse", LeftClick)
sleep(500)
ControlCommand("Remote Mouse", SetAbsolute, 72, 64)#Smart Arrange
sleep(200)
ControlCommand("Remote Mouse", LeftClick)
sleep(500)
ControlCommand("Remote Mouse", SetAbsolute, 30, 37)#File tab
sleep(200)
ControlCommand("Remote Mouse", LeftClick)
sleep(500)
ControlCommand("Remote Mouse", SetAbsolute, 852, 75)#2nd screen
sleep(200)
ControlCommand("Remote Mouse", LeftClick)
sleep(100)
ControlCommand("Remote Mouse", SetAbsolute, 229, 36)#Control tab
sleep(200)
ControlCommand("Remote Mouse", LeftClick)
sleep(500)
ControlCommand("Remote Mouse", SetAbsolute, 72, 64)#Smart Arrange
sleep(200)
ControlCommand("Remote Mouse", LeftClick)
sleep(500)
ControlCommand("Remote Mouse", SetAbsolute, 30, 37)#File tab
sleep(200)
ControlCommand("Remote Mouse", LeftClick)
sleep(500)
ControlCommand("Remote Mouse", SetAbsolute, 782, 73)#1st screen
sleep(200)
ControlCommand("Remote Mouse", LeftClick)

If anyone uses this example you'll need to change the screen location numbers to reflect what your Remote Mouse identifies.

#3  

Yeah, it is very handy. My only issue is that I run my projects on more than one computer, and they have different resolutions, so I need to update the script for the computer after I download the latest project version from the cloud when I make changes.

I save the script contents locally though, so it is not a major issue (and I am currently only using it in one project for one function, but I expect to use it more, including your use case).

Alan

Germany
#4  

Lol, i have found this post with google. Great work. This is really cool. Thanks