I'd like to make the following small Dialog unvisible on start of the DLL containing it:
As you can see, the above dialog is startable with option tfVisible.
When the DLL starts the dialog flickers for a tenth of a second and then disappears. But I'd like it to be unvisible at all with tfVisible = 0. How could I achive this even if the dialog is built during the load of the DLL?
Code:
'------------------------------------------------------------------------------------------------------- ' DIALOG '------------------------------------------------------------------------------------------------------- sub Watch(tfVisible as long) 'INPUT: 'tfVisible = 1: Dialog sichtbar 'tfVisible = 0: Dialog unsichtbar LOCAL hDlg AS LONG DIALOG NEW 0, "I B D WinInfo",,, 200, 80,, %WS_EX_TOOLWINDOW, TO hDlg 'Window nicht in Taskbar zeigen CONTROL ADD TEXTBOX, hDlg, 40, "", 4, 4, 190, 70, %ES_MULTILINE OR %ES_WANTRETURN OR %WS_VSCROLL, %WS_EX_CLIENTEDGE Dialog Show Modeless hDlg Call DlgProc 'Die Reichweite des Mauscursors auf den MCADD-Frame beschränken. '0& anstelle von GetHwndFrame() würde sich auf den gesamten Desktop-Inhalt beziehen. if tfVisible = 0 then SetWindowPos hDlg, %HWND_NOTOPMOST, GetHwndFrame(), 0, 0, 0, %SWP_HIDEWINDOW or %SWP_NOSIZE OR %SWP_NOMOVE ElseIf tfVisible = 1 Then SetWindowPos hDlg, %HWND_TOPMOST, GetHwndFrame(), 0, 0, 0, %SWP_SHOWWINDOW or %SWP_NOSIZE OR %SWP_NOMOVE end if End Sub
When the DLL starts the dialog flickers for a tenth of a second and then disappears. But I'd like it to be unvisible at all with tfVisible = 0. How could I achive this even if the dialog is built during the load of the DLL?
Comment