FAQ Database Discussion Community

How to use properties from Metrowindow above framed page

Using Mahapps.metro, and stumbling into a problem. I want to page paged content, all controlled via a frame within metro window. There are two things I cannot figure out how to do, which was easy enough whilst working all within one window without the pages. First off, I want to...

WPF DataTrigger with OpacityMask

i´m using Mahapps.Metro and want to change an icon depending on an Property. Here is the Mahapps sample for their Icons Setting only the Backgroundcolor("Fill") of the rectangle everything works fine. As soon as the OpacityMask is set the complete rectangle stays blank. <Rectangle Width="20" Height="20"> <Rectangle.Style> <Style TargetType="{x:Type Rectangle}">...

Setting an image as the title bar background

I can't see an obvious solution to this. I've been given an image file which includes both the "icon" and the text to be used in the title bar. Ideally I'd like to simply turn the icon off, use the image in the title bar section, and be done with...

MahApps - How to disable automatic uppercase of default button

I have started to introduce MahApps.Metro (really awesome) in my WPF application and my favorite button is the default. The problem is that it puts all my text in uppercase and I don't want it.

Metro.Mahapps Designer not showing

Hi I've been struggling with this bug and I have no clue how to resolve this. Basically the form designer giving me this error: Error 2 Could not load file or assembly 'MahApps.Metro, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified. But the application can...

UI Control Visibility Before Command Invocation?

I have a button command which sends several emails and therefore takes a few seconds for the method to execute. I want to show a progress ring Mahapps.Metro & disable the view whilst this method is executing. Here's my ProgressRing in my view: <Controls:ProgressRing IsActive="True" Visibility="{Binding IsProgressRingVisible, UpdateSourceTrigger=PropertyChanged}" /> ViewModel...

How to access ShowMessageAsync method of MetroWindow from ViewModel

I am using MahApps.metro WPF library with MVVM. I have a ViewModel from which I need to display a Dialog. The MetroWindow has ShowMessageAsync. But what is the proper way to access it from the ViewModel? As I understand I need a View instance but passing that into the ViewModel...

WPF 'Set property 'System.Windows.ResourceDictionary.DeferrableContent' threw an exception.'

My application runs fine in VS 2010 but when I copy the executable from the bin folder to another location I get this error: 'Set property 'System.Windows.ResourceDictionary.DeferrableContent' threw an exception.' Line number '15' and line position '23'. Did a bit of testing and found out that if I include the...

How to change MahApps.Metro dialog content template width?

I would like to change the base template of the MahApps.Metro dialogs (or create a new dialog type), because I would like to show them in a narrow login window. Right now almost all the second words in the message are in a new row, but there are nice big...

Style “Cannot find resource 'MetroCheckBox'” in MahApps

I'm starting to use styles in WPF. I'm using MahApps styles as a base, which so far has been really good. I've been able to make specific modifications using the BasedOn property. One of the simpler changes is to add a default margin so when adding controls they don't touch....

StickWindow in Mahapps

I'm trying to implement snapping to edges. I've found one answer here and implemented, however it destroys the chromeless window of Mahapps MetroWindow. I've adapted the solution to use Behaviors, so I'm going to share only the Behavior snnipet (you can find StickyWindow code here): Usage: <metro:MetroWindow x:Class="Communicator.Main.Views.ShellView" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"...

Add ErrorTemplate to a MahApp control without overwriting its default style

I am using MahApps and working on implementing validation for TextBoxes. MahApps provides some nice properties in TextBoxes, as Controls:TextBoxHelper.Watermark and Controls:TextBoxHelper.ClearTextButton. I am writing an ErrorTemplate using my style but I overwrite the default template of the TextBox and lose those Metro properties. How can I achieve my goal...

MahApps.Metro Progress Ring speed change

I use the progress ring in XAML like in the guide: <Controls:ProgressRing IsActive="True" /> Is there any way to control the speed of a progress ring?...

Setting focus to input box in an InputDialog using MahApps

We've made our own search dialog based on the InputDialog from MahApps Dialog examples, and it does work, but there are two issues with it: When opened it does not automatically focus in the search field, so you have to click it before starting to type your search If possible,...

Is MahApps.Metro needed for Windows 8.1 WPF app?

I am developing WPF app using Windows 7 and using MahApps.Metro library for Metro style UI. Now the default WPF app running in Windows 8.1 provides the same Metro Style, do I need to use MahApps for the styling? Is there any advantages for MahApps.Metro over default style? I don't...

ShowWindowCommandsOnTop not accessible in

Recently I upgraded to Mahapps from and I'm getting error on ShowWindowCommandsOnTop="False" as it is inaccessible. Where did it go?

Show/hide Mahapps Flyout control

How can I show/hide Mahapps Flyout control? Now I have: <controls:FlyoutsControl> <controls:Flyout Header="Flyout" Position="Right" Width="200" IsOpen="True"> <TextBlock FontSize="24">Hello World</TextBlock> </controls:Flyout> </controls:FlyoutsControl> And it's open, but when I click button with arrow I can't show it again. ...

Orchestra.MahApps custom window

I'm trying to create custom MahApps.Metro window with Orchestra framework. I have copied currennt ShellWindow content (both view + code behind) and created my own Window. Then in App.xaml.cs I have used my window instead of ShellWindow like this: shellService.CreateWithSplash<MyShellWindowView>() And problem is, that this window is not correctly styled...