コード例 #1
0
 public void Execute(object parameter)
 {
     Contact c = (Contact)parameter;
     Messages MessagePage = new Messages(c);
     App.Current.MainWindow = MessagePage;
     MessagePage.Show();
 }
コード例 #2
0
ファイル: MainWindow.xaml.cs プロジェクト: Motta92/Moviles
        private void toMessages(object sender, RoutedEventArgs e)
        {
            var item = (sender as FrameworkElement).DataContext;
            int index = ContactListView.Items.IndexOf(item);

            int contactIndex = Contacts.ElementAt(index).UserId;

            Console.WriteLine("Index of item clicked messages: " + contactIndex);

            Messages newMessageWpf = new Messages(contactIndex);
            newMessageWpf.Show();
        }