0

I've been struggling to figure this one out, therefore I figured it was time to finally ask you guys for assistance.

I've created a Visual Basic Win Form via Visual Studio to which I added multiple split containers to get different panels.

The issue that I'm having is that when I run the application, it looks different than what's in my design. I have recreated the project several times and have gone through the SplitContainer properties, however, I still can't figure this one out.

You can see what I'm talking about here:

Example image

Any and all assistance is greatly appreciated.

  • Do you have any code that is setting the `Location` of any of the controls explicitly? How are your controls `Anchored`? In particular, the `Orders` one. – pstrjds Nov 04 '18 at 16:49
  • Thanks for the response! The split container to the left has both panels (Customer, Orders) with the following properties: Anchor: Top, Left Dock: Fill I have not added any code to alter the location of the controls. – theStrugglingProgrammer Nov 04 '18 at 17:06
  • I once again created a new project and added nothing but the containers and a label where my 'Order' container should be... the label also gets pushed down as in the original image.... – theStrugglingProgrammer Nov 04 '18 at 17:37
  • You application is not DPIAware. As a consequence, it's subject to virtualization when the Screen DPI is different from the default 96Dpi. See this: [How to configure an app to run correctly on a machine with a high DPI setting (e.g. 150%)?](https://stackoverflow.com/questions/13228185/how-to-configure-an-app-to-run-correctly-on-a-machine-with-a-high-dpi-setting-e?answertab=active#tab-top). [Some notes I've written](https://stackoverflow.com/questions/50239138/dpi-awareness-unaware-in-one-release-system-aware-in-the-other?answertab=active#tab-top) – Jimi Nov 04 '18 at 19:25
  • 1
    @Jimi I know this reply is a little late, however, thats exactly what was going on! I appreciate your input which helped me address this issue. Edit: I've tried to have your response set as the 'Answer' to my question but it's not giving me the option to do so... I apologize I'm unable to do that! – theStrugglingProgrammer Nov 10 '18 at 17:38
  • @AndrewMorton thanks for the tip. Thanks! – theStrugglingProgrammer Nov 10 '18 at 18:05
  • @Jimi feel free to post it as an answer and I'll make it the accepted answer. Thanks! – theStrugglingProgrammer Nov 10 '18 at 18:05
  • 1
    No problem, it's Ok with me. @AndrewMorton correctly recalled the *etiquette*, but I had already seen your comment, where I put a +1. – Jimi Nov 10 '18 at 18:17

1 Answers1

0

The answer was provided by @Jimi: You application is not DPIAware. As a consequence, it's subject to virtualization when the Screen DPI is different from the default 96Dpi. See this: How to configure an app to run correctly on a machine with a high DPI setting (e.g. 150%)?. Some notes I've written