two questions

Apr 17, 2010 at 11:50 AM
Edited Apr 17, 2010 at 11:59 AM

sorry the first question i answered myself xD


and also, i'm still not quite sure as to how to invoke commands in the code.

like i've tried the Click="something" property.

then in my code i've got the

void something(object sender, RoutedEventArgs e)

{do whatever}


but it's not letting me, saying something about the class isn't referenced first as x:Class or whatever

then i tried doing this, but then the ribbon doesnt work :(


could you please explain to me how to do this xD

Apr 17, 2010 at 12:18 PM

Hi. Give us full source code, please.

Apr 17, 2010 at 1:07 PM

sure thing :)

<Fluent:RibbonWindow x:Class="Fluent.Sample.Foundation.Window"
Title="myApp" Width="635" Height="338" MinHeight="300" MinWidth="300" Icon="/TheApp;component/Images/Fluent.ico" xmlns:my="clr-namespace:System;assembly=mscorlib">
        <Fluent:Ribbon BackstageBrush="#FF525252">
        <Fluent:RibbonTabItem Header="Checker">
            <Fluent:RibbonGroupBox Header="Accounts" IsLauncherEnabled="True" IsLauncherVisible="False" IsOpen="False">
                <Fluent:Button Name="buttonImport" Text="Import" Icon="Images\Green.png" LargeIcon="Images\GreenLarge.png" Click="myEvent"/>
                <Fluent:Button Name="buttonExport" Text="Export" Icon="Images\Red.png" LargeIcon="Images\RedLarge.png" />

        <!--End Tabs-->
        <!--Backstage Items-->
            <Fluent:Button Text="Exit"  Command="{Binding ExitCommand}" Icon="Images\Blue.png"/>
            <Fluent:BackstageButton Text="blah" />
            <Fluent:BackstageButton Text="blah" />
            <Fluent:BackstageButton Text="blah" />
        <!--End Backstage Items-->

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
using Fluent;

namespace TheApp
    /// <summary>
    /// Interaction logic for Main.xaml
    /// </summary>
    public partial class Main : RibbonWindow
        public Main()

        private void myEvent(object sender, RoutedEventArgs e)


Apr 17, 2010 at 2:22 PM

And the errors, please...

Apr 17, 2010 at 4:49 PM
Edited Apr 17, 2010 at 4:50 PM

Maybe, error is in the first line in XAML, your class is named TheApp.Main, so fix it to <Fluent:RibbonWindow x:Class="TheApp.Main"

Am I right?