5/18/2023 0 Comments GetwindowtextReturns NULL, but the WM_DESTROY message is not sent to the window. If the hook procedure returns a nonzero value, the system destroys the window the CreateWindow function The system calls the hook procedure before sending the WM_CREATE or WM_NCCREATE message Please remember to mark the replies as answers if they help and unmark them if they provide no help.Ī window is about to be created. Interaction.Shell("C:\\Program Files\\Test\\WinApp-TestOP") IntPtr lpw = FindWindow(null, "Google - Windows Internet Explorer") Ĭonsole.WriteLine(SetWindowText(lpw, s)) Private void Button1_Click(System.Object sender, System.EventArgs e) Private static extern bool SetWindowText(IntPtr hwnd, string lpString) Private static extern IntPtr FindWindow(string lpClassName, string lpWindowName) Private static extern int GetWindowText(IntPtr hwnd, StringBuilder lpString, int cch) And here is code sample about this idea:
0 Comments
Leave a Reply. |