Sign in to follow this  
Followers 0
aarduini

Accessing Toolbar Icons

5 posts in this topic

Hello autoit members!

I am pretty new to autoit and I have a few questions.

I want to make a script to automate adding a new wireless network in Vista. Being new to this level of scripting, I don't know how to find the dll's and other various things to run some wizards.

I was wondering if there is a way to access the icons on the task bar beside the clock?

Any input would be greatly appreciated.

Share this post


Link to post
Share on other sites



Hello autoit members!

I am pretty new to autoit and I have a few questions.

I want to make a script to automate adding a new wireless network in Vista. Being new to this level of scripting, I don't know how to find the dll's and other various things to run some wizards.

I was wondering if there is a way to access the icons on the task bar beside the clock?

Any input would be greatly appreciated.

Welcome to the forum. There are a lot of scripts here on the forum that will probably help you out. Use the Search feature and search for words like "taskbar" and "icons" and I'm sure you'll find what you're looking for.

Auto3Lib: A library of over 1200 functions for AutoIt

Share this post


Link to post
Share on other sites

Welcome to the forum. There are a lot of scripts here on the forum that will probably help you out. Use the Search feature and search for words like "taskbar" and "icons" and I'm sure you'll find what you're looking for.

Thanks for the info, but i've done quite a bit of searching before I posted here. Im not able to find much about what I am actually looking for.

Share this post


Link to post
Share on other sites

Thanks for the info, but i've done quite a bit of searching before I posted here. Im not able to find much about what I am actually looking for.

I was able to find many examples with a simple search. Below is just one of those examples that I adopted from a post originally done by Larry using Auto3Lib:

#include <A3LToolbar.au3>

Opt("WinTitleMatchMode", 4)

$hWnd   = ControlGetHandle("classname=Shell_TrayWnd", "", "Notification Area")
$iCount = _Toolbar_ButtonCount($hwnd)

For $iI = 1 to $iCount
  $iCommand = _Toolbar_IndexToCommand($hWnd, $iI)
  $sText    = _Toolbar_GetButtonText ($hWnd, $iCommand)
  if $sText <> "" then ConsoleWrite($sText & @CR)
  ; If you want to click on this one, then use this
  ; _Toolbar_ClickButton($hWnd, $iCommand)
Next

The notification area is a Toolbar with buttons on it. The above script runs through the buttons, printing out the button text for each one. If it's a button of interest, you can click it (right or left), which would either activate the programs context menu or activate the program itself.


Auto3Lib: A library of over 1200 functions for AutoIt

Share this post


Link to post
Share on other sites

Aarduini,

Don't know if you're still seeking an answer, but just been working on a UDF that may be of interest to you, leveraging (heavily) PaulIA's work. The code is at http://www.autoitscript.com/forum/index.ph...hl=taskbar+menu if you want to see it/see how it works.

MisterBates

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  
Followers 0