Click here to Skip to main content
14,978,584 members
Home / Discussions / C#
   

C#

 
GeneralRe: Is there any SQL Server on the cloud for free? Pin
Alex Dunlop9-Jun-21 4:16
MemberAlex Dunlop9-Jun-21 4:16 
GeneralRe: Is there any SQL Server on the cloud for free? Pin
OriginalGriff9-Jun-21 4:26
mveOriginalGriff9-Jun-21 4:26 
QuestionHow to dynamically escape a character? Pin
Joseline Riker7-Jun-21 13:25
MemberJoseline Riker7-Jun-21 13:25 
AnswerRe: How to dynamically escape a character? Pin
Dave Kreskowiak7-Jun-21 15:06
mveDave Kreskowiak7-Jun-21 15:06 
AnswerRe: How to dynamically escape a character? Pin
OriginalGriff7-Jun-21 19:50
mveOriginalGriff7-Jun-21 19:50 
AnswerRe: How to dynamically escape a character? Pin
Richard MacCutchan7-Jun-21 21:14
mveRichard MacCutchan7-Jun-21 21:14 
AnswerRe: How to dynamically escape a character? Pin
Eddy Vluggen9-Jun-21 9:49
professionalEddy Vluggen9-Jun-21 9:49 
QuestionINotifyPropertyChanged/Changing: more useful in WPF compared to WinForms ? Pin
BillWoodruff7-Jun-21 11:35
mveBillWoodruff7-Jun-21 11:35 
note: this is not about AOP, IL weaving, Furty, PostSharp, etc., although those facilities are related to this discussion.

Context: in WinForms both these notification methods have, imho, very limited uses.

Do you use these mechanisms more frequently in WPF ? Are they valuable to you ? Essential/integral in MVVM ?

Have you ever developed your own notification-with-cancellation mechanism (i have, for WinForms).

0) there's an excellent overview of how INotifyPropertyChanged can be used in different C# versions by SO's resident genius, Marc Gravell: [^]

1) INotifyPropertyChanging has no cancel mechanism ... unless you consider throwing an error in some context you have no control over sweet-smelling code OMG | :OMG: According to PostSharp docs: "INotifyPropertyChanging interface is not portable (in Xamarin, it is even a part of a different namespace)."

2) INotifyPropertyChanged is just post-facto notification. There does appear to be a special benefit in using it with SQL and Linq: [^] ... i've never played with that.

Of course, you could trigger update of a binding connection. And, using Caller Information Attributes is easy in a Notify* changed handler ... imho, those attributes are of very limited value.

3) through "heroic" programming, you can create custom EventArgs that inherit from the INotify* versions and extend them to implement cancellation. however, in your subscribing objects' handlers you will have to cast the incoming args to their extended form.

there's an outstanding 2 article series here on CP from 2007: [^] that shows this kind of EventArgs extending as a way to get cancellation.
«One day it will have to be officially admitted that what we have christened reality is an even greater illusion than the world of dreams.» Salvador Dali


modified 7-Jun-21 22:00pm.

AnswerRe: INotifyPropertyChanged/Changing: more useful in WPF compared to WinForms ? Pin
Eddy Vluggen8-Jun-21 4:21
professionalEddy Vluggen8-Jun-21 4:21 
GeneralRe: INotifyPropertyChanged/Changing: more useful in WPF compared to WinForms ? Pin
BillWoodruff8-Jun-21 10:48
mveBillWoodruff8-Jun-21 10:48 
GeneralRe: INotifyPropertyChanged/Changing: more useful in WPF compared to WinForms ? Pin
Eddy Vluggen9-Jun-21 6:19
professionalEddy Vluggen9-Jun-21 6:19 
AnswerRe: INotifyPropertyChanged/Changing: more useful in WPF compared to WinForms ? Pin
Gary R. Wheeler13-Jun-21 8:26
MemberGary R. Wheeler13-Jun-21 8:26 
GeneralRe: INotifyPropertyChanged/Changing: more useful in WPF compared to WinForms ? Pin
BillWoodruff14-Jun-21 4:53
mveBillWoodruff14-Jun-21 4:53 
GeneralRe: INotifyPropertyChanged/Changing: more useful in WPF compared to WinForms ? Pin
Gary R. Wheeler14-Jun-21 5:05
MemberGary R. Wheeler14-Jun-21 5:05 
QuestionUpdated an application that uses DDE. Specific requirements. Pin
ptmaker7-Jun-21 10:52
Memberptmaker7-Jun-21 10:52 
AnswerRe: Updated an application that uses DDE. Specific requirements. Pin
Mycroft Holmes7-Jun-21 12:10
professionalMycroft Holmes7-Jun-21 12:10 
GeneralRe: Updated an application that uses DDE. Specific requirements. Pin
ptmaker8-Jun-21 3:19
Memberptmaker8-Jun-21 3:19 
QuestionRe: Updated an application that uses DDE. Specific requirements. Pin
Eddy Vluggen9-Jun-21 6:24
professionalEddy Vluggen9-Jun-21 6:24 
QuestionControlled replay of recorded data Pin
Chuck8446-Jun-21 9:47
MemberChuck8446-Jun-21 9:47 
AnswerRe: Controlled replay of recorded data Pin
Gerry Schmitz6-Jun-21 16:43
mveGerry Schmitz6-Jun-21 16:43 
GeneralRe: Controlled replay of recorded data Pin
Chuck8446-Jun-21 19:13
MemberChuck8446-Jun-21 19:13 
GeneralRe: Controlled replay of recorded data Pin
Dave Kreskowiak7-Jun-21 4:21
mveDave Kreskowiak7-Jun-21 4:21 
GeneralRe: Controlled replay of recorded data Pin
Gerry Schmitz7-Jun-21 7:08
mveGerry Schmitz7-Jun-21 7:08 
GeneralRe: Controlled replay of recorded data Pin
Mycroft Holmes7-Jun-21 12:18
professionalMycroft Holmes7-Jun-21 12:18 
AnswerRe: Controlled replay of recorded data Pin
BillWoodruff7-Jun-21 11:53
mveBillWoodruff7-Jun-21 11:53 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.