Jump to content

Mutli Gui and multi Process..??


Recommended Posts

How to Make Notepad button active ??

#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#include <StaticConstants.au3>

$Gui = GUICreate("Main Gui", 300, 200)
$Button = GUICtrlCreateButton("Notepad", 40, 20, 90, 30)
GUISetState(@SW_SHOW)

$CreditGui = GUICreate("Splash Gui", 200,30, -1, 0, $WS_POPUP, 0)
$splas = GUICtrlCreateLabel("Try Multi Gui Run Multi Process", 5, 5, 200, 30,$SS_CENTER)
GUICtrlSetFont(-1, 14, 400, 0, "Gloucester MT Extra Condensed")
GUISetState(@SW_SHOW)

While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
Case $Button
Run("notepad.exe")
EndSwitch
Sleep(2000)
DllCall("user32.dll", "int", "AnimateWindow", "hwnd", $CreditGui, "int", 1000, "long", 0x10010)
DllCall ( "user32.dll", "int", "AnimateWindow", "hwnd", $CreditGui, "int", 1000, "long", 0x00040010 )
WEnd

Thank's For All.. ;)

Edited by penggilas2
Link to comment
Share on other sites

In the WIki you can find a tutorial on how to handle multiple GUIs.

My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download
Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki
PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki
Task Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki

Standard UDFs:
Excel - Example Scripts - Wiki
Word - Wiki

Tutorials:
ADO - Wiki
WebDriver - Wiki

 

Link to comment
Share on other sites

The only way to do two things at the "same time" with AutoIt is to use AdLibRegister. This allows to run a function every x milliseconds and then return to the main script.

My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download
Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki
PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki
Task Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki

Standard UDFs:
Excel - Example Scripts - Wiki
Word - Wiki

Tutorials:
ADO - Wiki
WebDriver - 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...