Click here to Skip to main content
15,890,438 members
Home / Discussions / C#
   

C#

 
QuestionHow to subclass a Window Pin
Member 4337827-Oct-02 22:31
Member 4337827-Oct-02 22:31 
AnswerRe: How to subclass a Window Pin
Stephane Rodriguez.27-Oct-02 23:54
Stephane Rodriguez.27-Oct-02 23:54 
GeneralC#+VS.NET: my proxy is using the wrong library Pin
brotkopp27-Oct-02 5:40
brotkopp27-Oct-02 5:40 
GeneralRe: C#+VS.NET: my proxy is using the wrong library Pin
Stephane Rodriguez.27-Oct-02 7:09
Stephane Rodriguez.27-Oct-02 7:09 
GeneralRe: C#+VS.NET: my proxy is using the wrong library Pin
brotkopp27-Oct-02 8:34
brotkopp27-Oct-02 8:34 
GeneralRe: C#+VS.NET: my proxy is using the wrong library Pin
brotkopp31-Oct-02 9:57
brotkopp31-Oct-02 9:57 
GeneralHelp required on 5 issues - C# Pin
Fahad Khalil26-Oct-02 19:14
sussFahad Khalil26-Oct-02 19:14 
GeneralRe: Help required on 5 issues - C# Pin
David Stone26-Oct-02 19:40
sitebuilderDavid Stone26-Oct-02 19:40 
GeneralRe: Help required on 5 issues - C# Pin
Stephane Rodriguez.26-Oct-02 19:46
Stephane Rodriguez.26-Oct-02 19:46 
GeneralRe: Help required on 5 issues - C# Pin
leppie27-Oct-02 2:26
leppie27-Oct-02 2:26 
QuestionDiff. between properties and fields? Pin
Brian Olej26-Oct-02 9:46
Brian Olej26-Oct-02 9:46 
AnswerRe: Diff. between properties and fields? Pin
Daniel Turini26-Oct-02 9:58
Daniel Turini26-Oct-02 9:58 
GeneralRe: Diff. between properties and fields? Pin
Brian Olej26-Oct-02 10:02
Brian Olej26-Oct-02 10:02 
GeneralRe: Diff. between properties and fields? Pin
Anonymous26-Oct-02 10:06
Anonymous26-Oct-02 10:06 
GeneralRe: Diff. between properties and fields? Pin
Brian Olej26-Oct-02 10:26
Brian Olej26-Oct-02 10:26 
GeneralRe: Diff. between properties and fields? Pin
leppie26-Oct-02 10:14
leppie26-Oct-02 10:14 
GeneralRe: Diff. between properties and fields? Pin
Daniel Turini26-Oct-02 10:18
Daniel Turini26-Oct-02 10:18 
GeneralRe: Diff. between properties and fields? Pin
Jon Rista26-Oct-02 13:50
Jon Rista26-Oct-02 13:50 
GeneralRe: Diff. between properties and fields? Pin
Brian Olej29-Oct-02 8:45
Brian Olej29-Oct-02 8:45 
GeneralRe: Diff. between properties and fields? Pin
Brian Olej26-Oct-02 10:25
Brian Olej26-Oct-02 10:25 
GeneralRe: Diff. between properties and fields? Pin
Kevin McFarlane27-Oct-02 4:56
Kevin McFarlane27-Oct-02 4:56 
GeneralRe: Diff. between properties and fields? Pin
leppie27-Oct-02 5:00
leppie27-Oct-02 5:00 
AnswerRe: Diff. between properties and fields? Pin
LongRange.Shooter28-Oct-02 10:46
LongRange.Shooter28-Oct-02 10:46 
If I understand the question correctly...this may give a good definition.

Property: This is exposed via public accessors (get/set) that allow a user to indirectly modify an internal variable. This process allows the developer to a) encapsulate the actual data b) include process against the data before it is set in the variable c) define that variable as read-only / write-only / read/write-capable.

Field: Directly exposes an internal variable as PUBLIC. This, to some extent, breaks encapsulation, does not keep control of the variable within the control of the object, and is not CLS Compliant. No process can be performed against the public property (such as security or business logic) and as such the value of the variable should be treated as suspect by the owning object.

Does this help?

---------------------------------------------
Once I thought I was wrong
but I was happy to discover that was a mistake.


Condor

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.