Taimur Adil
Taimur Adil

Reputation: 77

MahApp.Metro configuration prob

I have just configured MahApp.Metro to my WPF form but after all configuration i got problems

public partial class MainWindow : MetroWindow
    {
        public MainWindow()
        {
            InitializeComponent(); << Red under line (does not exist in current context) >>
        }
    }

When i comment this section it run my application correctly but is it Good to comment this section?

Upvotes: 0

Views: 163

Answers (1)

DerAtrox
DerAtrox

Reputation: 183

I think you are using 2 diffrent namespaces/classnames in your .xaml and you .xaml.cs file.

If you have definded your x:Class (in the .xaml file of the form) as x:Class=Your.Namespace.YourClass the class of the .xaml file has to start with

namespace Your.Namespace {
    public partial class YourClass : MetroWindow {
        ...

Upvotes: 1

Related Questions