Jump to content

start a program and hide the task bar and close the program re-hide the taskbar


Gaia
 Share

Recommended Posts

hi

i'm new

i start to use autoit , i would like to learn 

for example i would like to hide the windows 10 taskbar when i start photoshop.exe and to unhide the taskbar when i close it

can somebody give a optimazed code about it?

i would like to optimaze at best the code

thanks

Link to comment
Share on other sites

1 hour ago, Subz said:

Normally pressing F key in Photoshop changes to Full Screen Mode (on top of taskbar), I've read that there are some issues with 1607 though but upgrading to 2017 appears to fix the issue.

hi

yes , but 2017 is very slow and buggy , you can read in their forum

i would like to use and write a script for this

it should wait for photoshop.exe and hide the taskbar , as soon i close photoshop it should un hide the taskbar

 

thanks

Link to comment
Share on other sites

Ok, here is the skinny. The settings for auto hiding the taskbar are not as simple as on / off unless you use the "built in" function. Changing the registry requires you to kill the 'explorer.exe' process and reload it for the changes to happen.. Sucks.. So.. Here is a quick and dirty work around. It will do the mouse movements to accomplish what you want, if your taskbar is on the bottom. It's not the ideal solution but works.

#Region ;**** Directives created by AutoIt3Wrapper_GUI ****
#AutoIt3Wrapper_Run_Tidy=y
#Tidy_Parameters=/tc 4 /reel
#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****

Opt("WinTitleMatchMode", 1) ;1=start, 2=subStr, 3=exact, 4=advanced, -1 to -4=Nocase
Opt("MouseCoordMode", 1) ;1=absolute, 0=relative, 2=client

Local $Properties

HotKeySet("{ESC}", "_Quit")

Run("Notepad.exe")

While 1
    Sleep(10)
    If ProcessExists("Notepad.exe") Then
        _HideTaskBar()
        _Quit()
    EndIf
WEnd

Func _HideTaskBar()
    $x = @DesktopWidth / 2
    $y = @DesktopHeight - 1

    MouseClick("right", $x, $y, 1, 1)
    MouseClick("left", $x + 5, $y - 5, 1, 1)
    Sleep(100)
    If WinExists("Taskbar and Start Menu Properties") Then
        $Properties = WinGetPos("Taskbar and Start Menu Properties")
        WinActivate("Taskbar and Start Menu Properties")
        MouseClick("left", $Properties[0] + 45, $Properties[1] + 118, 1, 1)
        Send("{ENTER}")
    EndIf
EndFunc   ;==>_HideTaskBar

Func _Quit()
    Exit
EndFunc   ;==>_Quit

 

 

Spoiler

WinSizer 2.1 (01/04/2017) - Download - [ Windows Layout Manager ]
Folder+Program (12/23/2016) - Download - [ USB Shortcut Creator ]

 

Link to comment
Share on other sites

1 hour ago, zone97 said:

Ok, here is the skinny. The settings for auto hiding the taskbar are not as simple as on / off unless you use the "built in" function. Changing the registry requires you to kill the 'explorer.exe' process and reload it for the changes to happen.. Sucks.. So.. Here is a quick and dirty work around. It will do the mouse movements to accomplish what you want, if your taskbar is on the bottom. It's not the ideal solution but works.

 

hi

thanks

is there a way to decompile an exe created with audit?

thanks

Link to comment
Share on other sites

  • 1 year later...

You can do that by doing one single AutoIT line. If you want the simple way : Just kill explorer.exe the task bar will desapear. But you willl still be able to use the computer.

You finish your script or your task by starting again explorer.exe.

My video tutorials : ( In construction )  || My Discord : https://discord.gg/S9AnwHw

How to Ask Help ||  UIAutomation From Junkew || WebDriver From Danp2 || And Water's UDFs in the Quote

Spoiler

 Water's UDFs:
Active Directory (NEW 2018-10-19 - Version 1.4.10.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (2018-10-31 - Version 1.3.4.1) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
PowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & Support
Excel - Example Scripts - Wiki
Word - Wiki
 
Tutorials:

ADO - Wiki

 

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...