c# - WPF OnNotifyPropertyChange Throws a null exception when instantiating an object -


i added field database , had update model database using ef. however, model shows correct fields , types. estimate class implement inotifypropertychanged well. working prior updating database, not sure went south

when traveling in debugger from:

currentestimate = new estimate(); 

to (as property changing):

private void notifypropertychanged([callermembername] string propertyname = "") {     propertychanged?.invoke(this, new propertychangedeventargs(propertyname)); } 

i null reference exception.

propertyname "currentestimate" , currentestimate not null once gets notifypropertychanged function.

implemnetation of currentestimate:

    private estimate _estimate;     public estimate currentestimate     {         { return _estimate; }         set { _estimate = value; notifypropertychanged(); }     } 

although exception being thrown at:

propertychanged?.invoke(this, new propertychangedeventargs(propertyname)); 

a custom converter culprit.


Comments

Popular posts from this blog

php - Embed BBCode within itself not working -

three.js - how to load gltf in three JS -

sql server - T-SQL: Access DB objects in same schema without qualifying? -