Jump to content

WinSetTrans


lilx
 Share

Recommended Posts

hello,

i was kinda bored and was looking true some stuff on the help and i saw winsettrans very funny to use and i would like to make a rogram that would make all me ie windows that are opend at the moment transparant, and i made this code

Opt("WinTitleMatchMode", 2); Match substring
$var = WinList("- Windows Internet Explorer")

$a = $var[0][0]
MsgBox ( 48, "Test", $a )

for $i = 1 to $a step 1
    WinSetTrans($var[$i][0], "", 215)
Next

but know it is only making one window tranparant what am i doing wrong?

Link to comment
Share on other sites

hello,

i was kinda bored and was looking true some stuff on the help and i saw winsettrans very funny to use and i would like to make a rogram that would make all me ie windows that are opend at the moment transparant, and i made this code

Opt("WinTitleMatchMode", 2); Match substring
$var = WinList("- Windows Internet Explorer")

$a = $var[0][0]
MsgBox ( 48, "Test", $a )

for $i = 1 to $a step 1
    WinSetTrans($var[$i][0], "", 215)
Next

but know it is only making one window tranparant what am i doing wrong?

Hi! Try this:

$aWin = WinList("[CLASS:IEFrame]")
If Not IsArray($aWin) Then
    MsgBox(16, "Error", "Required window(s) not exist")
    Exit
EndIf

For $i = 1 to $aWin[0][0]
    WinSetTrans($aWin[$i][1], "", 215)
Next

:D

Link to comment
Share on other sites

hey thanks for the reply and is working now :D

now i got a other question, i want that when a other ie opens that it makes that just open window transparant to, is there a way in autoit to detect that new window and make that one transparant

Link to comment
Share on other sites

hey thanks for the reply and is working now :)

now i got a other question, i want that when a other ie opens that it makes that just open window transparant to, is there a way in autoit to detect that new window and make that one transparant

HotKeySet("{Pause}", "Quit")

$aWin = WinList("[CLASS:IEFrame]")
If $aWin[0][0] = 0 Then
    MsgBox(16, "Error", "Required window(s) not exist")
    Exit
EndIf

For $i = 1 to $aWin[0][0]
    WinSetTrans($aWin[$i][1], "", 215)
Next

While 1
    Dim $aNewWindows = WinList("[CLASS:IEFrame]")
    For $i = 1 to $aNewWindows[0][0]
        For $j = 1 To $aWin[0][0]
            If $aNewWindows[$i][1] <> $aWin[$j][1] Then WinSetTrans($aNewWindows[$i][1], "", 215)
        Next
    Next
    Sleep(1000)
WEnd

Func Quit()
    $aWin = 0
    $aNewWindows = 0
    Exit
EndFunc

:)

Link to comment
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
 Share

  • Recently Browsing   0 members

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