Click here to Skip to main content
15,912,324 members
Home / Discussions / C#
   

C#

 
GeneralRe: Prevent repaint of a control (aka BeginUpdate, EndUpdate) Pin
r41n©18-Jul-07 3:04
r41n©18-Jul-07 3:04 
QuestionWebBrowser control and javascript files Pin
picazo17-Jul-07 12:36
picazo17-Jul-07 12:36 
Questionverify SQLServer access Pin
redivider17-Jul-07 12:19
redivider17-Jul-07 12:19 
AnswerRe: verify SQLServer access Pin
Luis Alonso Ramos17-Jul-07 14:25
Luis Alonso Ramos17-Jul-07 14:25 
GeneralRe: verify SQLServer access Pin
redivider18-Jul-07 4:30
redivider18-Jul-07 4:30 
GeneralRe: verify SQLServer access Pin
Luis Alonso Ramos18-Jul-07 5:29
Luis Alonso Ramos18-Jul-07 5:29 
GeneralRe: verify SQLServer access Pin
redivider18-Jul-07 6:39
redivider18-Jul-07 6:39 
QuestionSuggest me about MRCopy Pin
il_masacratore17-Jul-07 11:52
il_masacratore17-Jul-07 11:52 
QuestionAny one have Ideas for IT graduation Project Pin
michaelqog17-Jul-07 11:01
michaelqog17-Jul-07 11:01 
AnswerRe: Any one have Ideas for IT graduation Project Pin
dino209417-Jul-07 11:13
dino209417-Jul-07 11:13 
GeneralRe: Any one have Ideas for IT graduation Project Pin
Malcolm Smart17-Jul-07 11:18
Malcolm Smart17-Jul-07 11:18 
GeneralRe: Any one have Ideas for IT graduation Project Pin
Colin Angus Mackay17-Jul-07 11:29
Colin Angus Mackay17-Jul-07 11:29 
GeneralRe: Any one have Ideas for IT graduation Project Pin
Rao Rafique17-Jul-07 22:51
Rao Rafique17-Jul-07 22:51 
AnswerRe: Any one have Ideas for IT graduation Project Pin
Paul Conrad17-Jul-07 11:57
professionalPaul Conrad17-Jul-07 11:57 
QuestionProblem retrieving dataobjects stored on clipboard Pin
Sepharo17-Jul-07 10:59
Sepharo17-Jul-07 10:59 
QuestionLooping through Controls on a tab page Pin
greenb17-Jul-07 10:33
greenb17-Jul-07 10:33 
AnswerRe: Looping through Controls on a tab page Pin
Tarakeshwar Reddy17-Jul-07 10:44
professionalTarakeshwar Reddy17-Jul-07 10:44 
GeneralRe: Looping through Controls on a tab page Pin
BoneSoft17-Jul-07 10:49
BoneSoft17-Jul-07 10:49 
GeneralRe: Looping through Controls on a tab page Pin
PIEBALDconsult17-Jul-07 10:51
mvePIEBALDconsult17-Jul-07 10:51 
GeneralRe: Looping through Controls on a tab page Pin
Tarakeshwar Reddy17-Jul-07 10:58
professionalTarakeshwar Reddy17-Jul-07 10:58 
GeneralRe: Looping through Controls on a tab page Pin
PIEBALDconsult17-Jul-07 11:18
mvePIEBALDconsult17-Jul-07 11:18 
GeneralRe: Looping through Controls on a tab page Pin
BoneSoft17-Jul-07 11:32
BoneSoft17-Jul-07 11:32 
GeneralRe: Looping through Controls on a tab page Pin
PIEBALDconsult17-Jul-07 11:43
mvePIEBALDconsult17-Jul-07 11:43 
GeneralRe: Looping through Controls on a tab page Pin
BoneSoft17-Jul-07 12:08
BoneSoft17-Jul-07 12:08 
GeneralRe: Looping through Controls on a tab page [modified] Pin
PIEBALDconsult17-Jul-07 17:17
mvePIEBALDconsult17-Jul-07 17:17 
Preliminary results confirm my theory:

as works well with a homogenous collection

is works well with a heterogenous collection

But cast/catch/ignore also works well with a homogenous collection, at times even better than as ! (Not that I recommend it... much.) It is horrible with a heterogenous collection.


On the other hand, as doesn't work with value types, but I've had success testing it with nullable types.


-- modified at 23:52 Tuesday 17th July, 2007

Whoops, need to add that the if ( o.GetType() == typeof(sometype) ) method is faster than both is and as, but at the cost of not checking the inheritance tree.

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.