Search the Community
Showing results for tags 'Create outlook profile'.
-
Heya, I'm trying to create an Outlook profile by running the tool included in Office (C:Program Files (x86)Microsoft OfficeOffice14MLCFG32.CPL) I don't want the user to interact with nor see the guide itself so i tried using Universalists excelent hook found here: '?do=embed' frameborder='0' data-embedContent>> This method only seems to work for a single GUI, once the "Show profiles" button is clicked a new window is opened, the hook looses the "link" and the new window "flickers" before i manage to make it transparent. Could someone help me either modify my script or in some other way hide created windows before they're drawn? Mind the window-titles being in swedish Local $Email $GUIHook = GUICreate('Autoit Hook GUI') ;A GUI is needed to catch the messages. $SystemHook = DllCall('user32.dll', 'int', 'RegisterWindowMessageW', 'wstr', 'SHELLHOOK') ;This the hook cut down and simplifed. Check link for a more detailed info on it. GUIRegisterMsg($SystemHook[0], "GUIHook") ;Is the function you want to regesiter the Hook to. "GUIHook" DllCall('user32.dll', 'int', 'RegisterShellHookWindow', 'hwnd', $GUIHook) ;Links it to your GUI so you can see the messages. Run('control "C:\Program Files (x86)\Microsoft Office\Office14\MLCFG32.CPL"') ;Runs the Program While 1 Sleep(250) ;This is to keep the script alive, check HotKeySet in HelpFile. Its the same idea. WEnd Func GUIHook($hWnd, $Msg, $wParam, $lParam) Switch StringRight($wParam, 1) Case 1 ;Window Created If WinGetTitle("Konfigurera e-post") And $Email = 0 Then $Email = 1 WinSetTrans(WinGetTitle("Konfigurera"), "", 100) ControlClick(WinGetTitle("Konfigurera"), "", "Button3") ;Clicking this button breaks the link. WinWait("E-post") WinSetTrans(WinGetTitle("E-post"), "", 100) ControlClick(WinGetTitle("E-post"), "", "Button1") Exit EndIf EndSwitch EndFunc ;==>GUIHook