Information générale
Catégorie:
The Mere Mortals .NET Framework
When I create a new MM WPF Project, change the data connections to the northwind data, run the program, click on List/Users, the user window is displayed, but data is not displayed, and none of the buttons work. There is some code commented out, that would get the entities. I tried un-commenting this , and modified it as shown below, but Users does not have a GetAllEntities. Should User have a GetAllEntities method?
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Navigation;
using OakLeaf.MM.Main.WPF;
using OakLeaf.MM.Main.Business;
namespace FrogWare.WPFTest3.Desktop
{
public partial class UsersWindow : mmBusinessWindow
{
//protected User User;
public UsersWindow()
{
//this.User = this.User = (User)this.RegisterPrimaryBizObj(new User());
this.InitializeComponent();
// Get all user entities
//this.lstList.ItemsSource = this.User.GetAllEntities();
=========================== Modified ========================================
using OakLeaf.MM.Main.Security;
using OakLeaf.MM.Main.WPF;
using OakLeaf.MM.Main.Business;
namespace FrogWare.WPFTest3.Desktop
{
public partial class UsersWindow : mmBusinessWindow
{
protected mmUser User;
public UsersWindow()
{
this.User = (mmUser)this.RegisterPrimaryBizObj(new mmUser());
this.InitializeComponent();
// Get all user entities
this.lstList.ItemsSource = this.User.GetAllEntities();
Thanks for your help.
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement