Jump to content

about windows taskbar


Chinesegirl
 Share

Recommended Posts

Hi,

Welcome to the forum. Nice first question if I may say so..:)

This will get you the handle. Search for Shell_TrayWnd for more info.

Func testTrayBar()
   opt("WinTitleMatchMode",4)
   dbg(WinGetHandle("classname=Shell_TrayWnd"))
EndFunc

Happy scripting.

Link to comment
Share on other sites

whatever hidden or show,All return the same result . It is impossible to judge the status of windows taskbar

All result showed 0*0003004c

which language is "DBG"?

run "dbg" tip error !

As follows:

"ERROR: dbg(): undefined function. dbg(WinGetHandle("classname=Shell_TrayWnd"))"

Thanks

Link to comment
Share on other sites

I did not provide all the code to do what you want. I did however provide the most important part to figure out what you want in the forum. It has been done before. Like most things. So, did you do a search for +classname +Shell_TrayWnd ???

dbg is a udf (my own). From the code you should be able to figure out how it works. Even a search would have helped as I have posted it several times the last week. But, ok, from the top of my head:

Func dbg($msg, $erl=@ScriptLineNumber, $err=@Error, $ext=@Extended)
    ;NOTE: Double click on a line with this format in SciTE will make it jump to the line in the current buffer.
    ConsoleWrite("(" & $erl & ") := (" & $err & ")(" & $ext &  "): " & $msg & @LF)
    If $err <> 0 OR $ext <> 0 Then Return SetError($err, $ext, 0)
    Return 1
EndFunc

So, all you get from the code in my first post is a window handle. That handle can be used in other Win* functions to figure out if the window is visible or not. I'm not on windows now so I can't help with that at the moment, sorry.

There is another solution to. The start button has a rather specific icon in it. SO you could use PixcelGetColor at the startbuttons coordinates (the red and blue area) to figure out if it is visible or not.

Happy Scripting

Link to comment
Share on other sites

  • 4 weeks later...

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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...