Jump to content

Making Inputbox open on same monitor as GUI


PartyPooper
 Share

Recommended Posts

I have a two monitor system and I have a program that displays the GUI on the secondary monitor. When the program opens up an InputBox, it displays it on the primary monitor instead of the secondary monitor where the GUI is located. This is fast becoming a PITA. Is there any way to sticky the InputBox to the GUI? I thought by using the hwnd option of the InputBox and pointing it to the window handle of the parent ($hMainGUI) this would solve the problem but it doesn't. I've tried the following without success:

Local $sInfo = InputBox("Display Information", "Enter Question(case insensitive):", "", "", 250, 110, -1, -1, "", $hMainGUI)
Local $sInfo = InputBox("Display Information", "Enter Question(case insensitive):", "", "", 250, 110, 0, 0, "", $hMainGUI)
Local $sInfo = InputBox("Display Information", "Enter Question(case insensitive):", "", "", 250, 110, "", "", "", $hMainGUI)
Local $sInfo = InputBox("Display Information", "Enter Question(case insensitive):", "", "", 250, 110, Default, Default, "", $hMainGUI)

Any ideas?

Link to comment
Share on other sites

What happens if you create a second GUI that is child of the first? If it appears on the right monitor you could use it to make a custom InputBox.

I could but it would mean a significant increase in coding which I want to avoid. If I can't find a solution to this, I may have to end up identifying the main GUIs coordinates and calculating a position from that. Means more coding but less than having to create custom input boxes and input checks.

Thanks for the idea anyway.

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...