Click here to Skip to main content
15,895,142 members
Home / Discussions / C#
   

C#

 
QuestionHow to identify the application has been executed or not? Pin
BalasubramanianK2-Feb-10 19:22
BalasubramanianK2-Feb-10 19:22 
AnswerRe: How to identify the application has been executed or not? Pin
BalasubramanianK2-Feb-10 19:40
BalasubramanianK2-Feb-10 19:40 
Questiongdiplus jpeg encodng performance? Pin
Druuler2-Feb-10 17:29
Druuler2-Feb-10 17:29 
QuestionA good looking TreeView Pin
newstargate2-Feb-10 11:15
newstargate2-Feb-10 11:15 
AnswerRe: A good looking TreeView Pin
Super Lloyd2-Feb-10 11:28
Super Lloyd2-Feb-10 11:28 
AnswerRe: A good looking TreeView Pin
Anurag Gandhi2-Feb-10 19:23
professionalAnurag Gandhi2-Feb-10 19:23 
JokeRe: A good looking TreeView Pin
Ravi Bhavnani3-Feb-10 2:06
professionalRavi Bhavnani3-Feb-10 2:06 
QuestionDecryption algorithm Pin
3bood.ghzawi2-Feb-10 9:34
3bood.ghzawi2-Feb-10 9:34 
AnswerMessage Closed Pin
2-Feb-10 9:56
stancrm2-Feb-10 9:56 
GeneralRe: Decryption algorithm Pin
3bood.ghzawi2-Feb-10 11:42
3bood.ghzawi2-Feb-10 11:42 
GeneralRe: Decryption algorithm Pin
Mycroft Holmes2-Feb-10 11:57
professionalMycroft Holmes2-Feb-10 11:57 
GeneralRe: Decryption algorithm Pin
AspDotNetDev2-Feb-10 16:57
protectorAspDotNetDev2-Feb-10 16:57 
GeneralRe: Decryption algorithm [modified] Pin
Not Active2-Feb-10 11:58
mentorNot Active2-Feb-10 11:58 
Questionproblem of socket programming with local ip Pin
mehrdad3332-Feb-10 8:38
mehrdad3332-Feb-10 8:38 
AnswerRe: problem of socket programming with local ip Pin
Jimmanuel2-Feb-10 9:29
Jimmanuel2-Feb-10 9:29 
QuestionMs Access reports saving to File system in C# Pin
montu33772-Feb-10 8:34
montu33772-Feb-10 8:34 
AnswerRe: Ms Access reports saving to File system in C# Pin
Mycroft Holmes2-Feb-10 12:01
professionalMycroft Holmes2-Feb-10 12:01 
GeneralBluetooth programming Pin
Jamal Abdul Nasir2-Feb-10 8:31
Jamal Abdul Nasir2-Feb-10 8:31 
GeneralRe: Bluetooth programming Pin
Ennis Ray Lynch, Jr.2-Feb-10 8:35
Ennis Ray Lynch, Jr.2-Feb-10 8:35 
GeneralRe: Bluetooth programming Pin
Giorgi Dalakishvili2-Feb-10 23:05
mentorGiorgi Dalakishvili2-Feb-10 23:05 
QuestionWhen To Use 'this' in C# Pin
Matt U.2-Feb-10 8:15
Matt U.2-Feb-10 8:15 
AnswerRe: When To Use 'this' in C# Pin
Abhinav S2-Feb-10 8:21
Abhinav S2-Feb-10 8:21 
AnswerRe: When To Use 'this' in C# Pin
OriginalGriff2-Feb-10 8:25
mveOriginalGriff2-Feb-10 8:25 
GeneralRe: When To Use 'this' in C# Pin
Matt U.2-Feb-10 10:55
Matt U.2-Feb-10 10:55 
AnswerRe: When To Use 'this' in C# Pin
Ennis Ray Lynch, Jr.2-Feb-10 8:25
Ennis Ray Lynch, Jr.2-Feb-10 8:25 
Unfortunately, this is a suggested requirement of FXCOP and it is a very poor programming practice. It is my opinion that the over-user of the this keyword came from ignorant programmers who did not know of the keyboard shortcut for intellisense (ctrl + space) these ignorant programmers then went on to define a standard because they wanted code to be "readable" thus it became a standard. It then made it into FXCOP which is a MS tool and then, because it is an MS tool other companies "architects" decided that if MS does it then it must be good. However, MS code rarely, if ever passed through the recommended FXCOP settings without warnings ... to make a long story short:

Don't use this unless you really need to. The only real good time to use the keyword is when calling a method from another object that required a reference to the calling object such as:

public class Foo{

    public Foo(){
        Bar bar = new Bar(this);
    }
}
public class Bar{
    public Bar(Foo foo){}
}


In all other cases where you would be tempted to use the keyword you have inappropriately named your local and member variables. Fix them.


Need custom software developed? I do custom programming based primarily on MS tools with an emphasis on C# development and consulting.

A man said to the universe:
"Sir I exist!"
"However," replied the universe,
"The fact has not created in me
A sense of obligation."
--Stephen Crane


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.