Click here to Skip to main content
15,887,027 members
Home / Discussions / C#
   

C#

 
AnswerRe: I want to run program on background . pref C# Pin
Giorgi Dalakishvili23-Nov-08 22:14
mentorGiorgi Dalakishvili23-Nov-08 22:14 
QuestionRemoving components Pin
B8723-Nov-08 21:29
B8723-Nov-08 21:29 
QuestionForeach Item in... Pin
jas0n2323-Nov-08 21:19
jas0n2323-Nov-08 21:19 
AnswerRe: Foreach Item in... Pin
Guffa23-Nov-08 21:31
Guffa23-Nov-08 21:31 
AnswerRe: Foreach Item in... Pin
Giorgi Dalakishvili23-Nov-08 21:33
mentorGiorgi Dalakishvili23-Nov-08 21:33 
AnswerRe: Foreach Item in... Pin
Pedram Behroozi23-Nov-08 21:34
Pedram Behroozi23-Nov-08 21:34 
GeneralRe: Foreach Item in... Pin
jas0n2323-Nov-08 21:51
jas0n2323-Nov-08 21:51 
GeneralWhat's the difference using a cast or C#'s 'as' [modified] Pin
Martin Hart Turner23-Nov-08 21:17
Martin Hart Turner23-Nov-08 21:17 
Hi:

I see in lots of sample code something like this:

Customer customer = (Customer)e.NewObject;


but I always prefer:

Customer customer = e.NewObject as Customer;


I can then test for 'customer' being null, but is there and *real* difference of performance hit?

---
Regards,
Martin.

modified on Monday, November 24, 2008 4:53 AM

GeneralRe: What's the difference using a cast or C#'s 'as' Pin
Baconbutty23-Nov-08 21:36
Baconbutty23-Nov-08 21:36 
GeneralRe: What's the difference using a cast or C#'s 'as' Pin
leppie23-Nov-08 22:22
leppie23-Nov-08 22:22 
GeneralRe: What's the difference using a cast or C#'s 'as' Pin
Simon P Stevens23-Nov-08 22:16
Simon P Stevens23-Nov-08 22:16 
GeneralRe: What's the difference using a cast or C#'s 'as' Pin
Martin Hart Turner23-Nov-08 22:38
Martin Hart Turner23-Nov-08 22:38 
GeneralRe: What's the difference using a cast or C#'s 'as' Pin
James Simpson23-Nov-08 22:48
James Simpson23-Nov-08 22:48 
GeneralRe: What's the difference using a cast or C#'s 'as' Pin
Simon P Stevens23-Nov-08 22:59
Simon P Stevens23-Nov-08 22:59 
GeneralRe: What's the difference using a cast or C#'s 'as' Pin
James Simpson23-Nov-08 23:07
James Simpson23-Nov-08 23:07 
GeneralRe: What's the difference using a cast or C#'s 'as' Pin
Simon P Stevens23-Nov-08 23:12
Simon P Stevens23-Nov-08 23:12 
GeneralRe: What's the difference using a cast or C#'s 'as' Pin
Simon P Stevens23-Nov-08 22:57
Simon P Stevens23-Nov-08 22:57 
GeneralRe: What's the difference using a cast or C#'s 'as' Pin
Martin Hart Turner23-Nov-08 23:37
Martin Hart Turner23-Nov-08 23:37 
GeneralRe: What's the difference using a cast or C#'s 'as' Pin
Chris Maunder23-Nov-08 22:53
cofounderChris Maunder23-Nov-08 22:53 
QuestionReplaces "[fieldname]" in the HTML template document with data from the corresponding column of the SQLite table. Pin
Tsodgorhuu23-Nov-08 21:00
Tsodgorhuu23-Nov-08 21:00 
AnswerRe: Replaces "[fieldname]" in the HTML template document with data from the corresponding column of the SQLite table. Pin
Thomas Weller23-Nov-08 21:30
Thomas Weller23-Nov-08 21:30 
AnswerRe: Replaces "[fieldname]" in the HTML template document with data from the corresponding column of the SQLite table. Pin
Ashfield23-Nov-08 21:50
Ashfield23-Nov-08 21:50 
GeneralRe: Replaces "[fieldname]" in the HTML template document with data from the corresponding column of the SQLite table. Pin
Guffa23-Nov-08 23:09
Guffa23-Nov-08 23:09 
QuestionA program to delete first n bytes in a file Pin
Matjaz-xyz23-Nov-08 20:47
Matjaz-xyz23-Nov-08 20:47 
AnswerRe: A program to delete first n bytes in a file Pin
Christian Graus23-Nov-08 20:50
protectorChristian Graus23-Nov-08 20:50 

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.