Jump to content
Sign in to follow this  
mv2112

Problem with List Selection

Recommended Posts

mv2112

First of all, im mv2112, and im new here :) . Justa a young programmar dabbleing in many different programming and scripting languages. I do, however, use AutoIT for work, which is what i currently need help with.

At work, i use Radmin Viewer to remotly login to other computers for administration. Im trying to write scripts that help automate the update process. Right now i have a script that works perfectly, it:

  • Upload Update Files
  • Sheduals them to Run on Login
  • Logs In
The only problem is with the Radmin GUI. The computer names are listed in a SysListView32 object, so in order to access the computer, I have to select an option and hit enter. The problem is that even though i select a SysListView32 option with ControlListView(), the option itself is highlighted but there is still a gray box around another option. This causes the enter button to fail. It apears that i need to click the option to select it. Is there anyway to completely select the SysListView32 objects directly from script without manipulating the mouse?

This is the Code i use to find and select options:

$pcname="ComputerName01"
    ControlListView("Radmin Viewer","","SysListView321","SelectClear")
    $handle=ControlGetHandle("Radmin Viewer","","SysListView321")
    $vData=ControlListView("Radmin Viewer","","SysListView321","FindItem",$pcname)
    ControlListView("Radmin Viewer","","SysListView321","Select",$vData)

I could post the whole script if needed but it is messy and iv fiddled with it a bit ;)


There's no place like ~/

Share this post


Link to post
Share on other sites
sleepydvdr

I have never used that software, but a quick search revealed that it accepts switches that can be used to directly control the program:

http://radmin.helpmax.net/en/using-radmin-viewer/radmin-viewer-interface/command-line-switches/


#include <ByteMe.au3>

Share this post


Link to post
Share on other sites
mv2112

:) How did i miss that? Well, this GREATLY simplifies things! Thanks a bunch!

Also, i have 1 small question about AutoIT itself:

Does AutoIT have something like this in C++?

int somenumber=(foo>bar)?5:-5;

Thanks again!

;)


There's no place like ~/

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.