Hedge
Hedge

Reputation: 16748

Disable fullscreen/maximise button in UWP-application?

I'm working on a Universal Windows Platform-application for desktop platforms. How can I disable/remove the maximise-button from a <page> or <application> in Windows 10?

Upvotes: 4

Views: 6612

Answers (4)

Kuldeep
Kuldeep

Reputation: 537

We can hide the maximize and minimize buttons by the ResizeMode property in our .xaml like this

ResizeMode="NoResize" //CanMinimize || CanResize || CanResizeWithGrip

Resize mode will allow any of the four values for the Window element in the form.

Upvotes: -2

saurabh
saurabh

Reputation: 724

There could be another workaround for this : Although you cannot disable the AppTitle bar but you can try entering your view to full view so that it covers up the Title bar and then you can add a custom title bar if you need to customize the functionality.

https://social.msdn.microsoft.com/Forums/windowsapps/en-US/830607c5-0b2a-4309-b59c-ab4b381cf128/what-is-the-easiest-way-to-show-full-screen-button-in-the-app-title-bar?forum=wpdevelop#9b3d0f1a-dfa9-4949-8785-80a74e911790

Upvotes: 0

saurabh
saurabh

Reputation: 724

If the objective of removing the Maximize/Minimize button is to run the app in Kiosk mode then you can see something like https://technet.microsoft.com/itpro/windows/manage/set-up-a-kiosk-for-windows-10-for-desktop-editions

However, you cannot remove these things programatically

Upvotes: 1

You cannot. I didn't see any option to disable these buttons. You can only change their colors.

ApplicationViewTitleBar titlebar = ApplicationView.GetForCurrentView().TitleBar;

titlebar.ButtonBackgroundColor = Windows.UI.Color.FromArgb(255, 126, 188, 66);
titlebar.ButtonForegroundColor = Windows.UI.Colors.White;

Upvotes: 1

Related Questions