I used the RadControlsScenario to create a Window just to see how it works and things went well until I tried to Compile and open it. The first think I found was no RadControlsScenario.Show(), How do you show the window. The second is The name 'InitializeComponent' does not exist in the current context. My namespace is the same as the main window that would be calling it.
An object reference is required for the non-static field, method, or property 'System.Windows.Window.ShowDialog()'
Built with RadControl Scenario
Where I try to open it from my main Window
An object reference is required for the non-static field, method, or property 'System.Windows.Window.ShowDialog()'
Built with RadControl Scenario
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.Shapes;
using System.Threading.Tasks;
using Telerik.Windows.Controls;
namespace My.Controls
{
/// <
summary
>
/// Interaction logic for RadSalesPersonRCS1.xaml
/// </
summary
>
public partial class RadSalesPersonRCS1 : Window
{
public RadSalesPersonRCS1()
{
InitializeComponent();
}
}
}
Where I try to open it from my main Window
private void MenuItem_ViewSalesPerson(object sender, RoutedEventArgs e)
{
RadSalesPersonRCS1 salesperson = new RadSalesPersonRCS1();
RadSalesPersonRCS1.ShowDialog();
}