Faced the problem of resizing a UWP window.

I tried to resize the window in the XAML markup using the Height and Weight properties, the result did not give - the contents of the window are compressed in the specified sizes, and the window remains in the same proportions. I also tried to change the window initialization method:

ApplicationView.GetForCurrentView().SetPreferredMinSize(new Size { Height = 300, Width = 500 }); 

Similarly, the results did not give.

Please tell me how to resize the window.

  • Link , just keep in mind that sizes are set in "effective" pixels - Andrew NOP
  • Thank. It seems that the window is changing in size, but only there are two problems: every time the window changes in size by itself, and there is also a certain minimum size limit. Attempting to change the MinWidth / MinHeight properties does not help - Artyom Kirgizov
  • Well, in UWP, the concept of a window itself is absent and you don’t have to explicitly manage it, the system may not let you resize at all, since the application can be launched on the system in tablet mode or on mobile Win10. Maybe you should use WPF or develop several views with different layout of elements for different devices - Andrey NOP
  • And if, let's say, the application will only be used primarily in Windows 10, and one of the windows should not be larger than it? As an example, I can give the registration window in the system. How can you get out of this situation? - Artem Kirgizov
  • I would use some Flyout / Popup / ToolTip . There are also some dialog pseudo-windows, but I'm not sure that they are completely custom - Andrey NOP

0