I am having problems with Namespaces, I seem to be chasing the error around and now I am down to one left that I don’t understand. All my files have the same namespace, I don’t really think I need more then one for a small program.
Example.xaml
<UserControl x:Class="Example"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"
xmlns:chart="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.Chart"
xmlns:chartView="clr-namespace:Telerik.Windows.Controls.ChartView;assembly=Telerik.Windows.Controls.Chart"
xmlns:telerikQuickStart="clr-namespace:Telerik.Windows.Controls.QuickStart;assembly=Telerik.Windows.Controls"
xmlns:local="clr-namespace:Example.ExampleViewModel"
xmlns:System="clr-namespace:System;assembly=mscorlib">
<telerikQuickStart:QuickStart.ExampleHeader>
<TextBlock Text="Atlanta Sales Dashboard" Margin="8" />
</telerikQuickStart:QuickStart.ExampleHeader>
<UserControl.DataContext>
<local:ExampleViewModel />
</UserControl.DataContext> /
ExampleViewModel.cs
using System;
using System.Collections.ObjectModel;
using System.Linq;
using Telerik.Windows.Controls;
using Telerik.Windows.Controls.Map;
using System.Collections.Generic;
using System.Globalization;
using System.Windows;
using System.Windows.Resources;
using System.Xml;
namespace Example.ExampleViewModel
{
public class ExampleViewModel : ViewModelBase
The ExampleViewModel is still giving me the following errors.
Error 1 The name "ExampleViewModel" does not exist in the namespace "clr-namespace:Example.ExampleViewModel". D:\visual studio 12\Projects\Map1\Map1\Example.xaml 14 9 Map1
Error 2 The namespace '<global namespace>' already contains a definition for 'Example' D:\visual studio 12\Projects\Map1\Map1\obj\x86\Debug\Example.g.cs 62 22 Map1
After searching this out I finally cleaned that error out with the help from the following: http://windowsclient.net/learn/video.aspx?v=31429
But this moved me to another error that i am going to contact Telerik on. It seems they are using a control which is in another namespace.
Thanks