Questions tagged [setwindowpos]

19 questions
0
votes
1 answer

SetWindowPos not doing anything despite providing all parameters

I have imported SetWindowPos and GetForegroundWindow: [DllImport("user32.dll", CharSet = CharSet.Ansi)] private static extern IntPtr GetForegroundWindow(); [DllImport("user32.dll", CharSet = CharSet.Ansi)] static extern bool SetWindowPos(IntPtr…
JonnyLee
  • 85
  • 7
0
votes
1 answer

Start a program on different screen

I've already checked out: SetWindowPos not working on Form.Show() Launch an application and send it to second monitor? However, none of these solutions seem to work for me. I want to open an external program on a different monitor. This is my…
mrid
  • 5,782
  • 5
  • 28
  • 71
0
votes
1 answer

c# Programmatically move Citrix window

Using the next answer I am trying to programmatically reposition a citrix window, somehow the window does not move. I assume the process name that holds the Citrix window is one of the next processes that were added in Process.GetProcesses() after I…
Avishay
  • 305
  • 1
  • 11
0
votes
2 answers

The correct method for drawing a bitmap image into a window

I have a function which takes a rectangular region of a bitmap image, rescales it to different dimensions, and draws it at some offset inside of a window within my dialog-box application: void DrawImage(HANDLE hImageBitmap, CDC*…
goodvibration
  • 5,980
  • 4
  • 28
  • 61
1
2