Solved

INotifyPropertyChanged w/ ADO.NET Entity and RadGridView WPF vb.net

Posted on 2010-11-11
2
1,061 Views
Last Modified: 2012-05-10
Hi,

I am using an ADO.NET Entity of my SQL Server database as the business object for the itemsource of a Telerik RadGridView in WPF (vb).  How can I implement INotifyPropertyChanged so that the grid can maintain up to date data?  
0
Comment
Question by:ccwestbrook
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 15

Accepted Solution

by:
x77 earned 500 total points
ID: 34114307
Implemnt the INotifyPropertyChanged is easy

You add the Implements clause to your class:

Friend Class Rgra
    Implements INotifyPropertyChanged


This add a Event to your Class

    Public Event PropertyChanged As PropertyChangedEventHandler _
        Implements INotifyPropertyChanged.PropertyChanged


You can then Raise the event on each Set Property

     Public Property mLeft() As Double
        Get
            Return _mLeft
        End Get
        Set(ByVal value As Double)
            _mLeft = value
           RaiseEvent PropertyChanged(Me, New PropertyChangedEventArgs("mLeft"))
        End Set
    End Property


But note that you are using  a String "mLeft" to do it.
You can read an excelent article to avoid that.

http://www.deanchalk.me.uk/post/WPF-e28093-Easy-INotifyPropertyChanged-Via-DynamicObject-Proxy.aspx
0
 

Author Comment

by:ccwestbrook
ID: 34114621
Thanks.  The problem I have is the ADO.NET Entity is an .edmx xml file, not a .vb class file.  I read that INotifyPropertChanged can be used for it but I don't see how.  
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Introduction When many people think of the WebBrowser (http://msdn.microsoft.com/en-us/library/2te2y1x6%28v=VS.85%29.aspx) control, they immediately think of a control which allows the viewing and navigation of web pages. While this is true, it's a…
The ECB site provides FX rates for major currencies since its inception in 1999 in the form of an XML feed. The files have the following format (reducted for brevity) (CODE) There are three files available HERE (http://www.ecb.europa.eu/stats/exch…
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…

696 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question