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

C#

 
AnswerRe: Developing LogonUI With C# ? Pin
Abhishek Sur28-Oct-09 5:19
professionalAbhishek Sur28-Oct-09 5:19 
Questionrelated to crystal report Pin
NarendraSinghJTV28-Oct-09 3:31
NarendraSinghJTV28-Oct-09 3:31 
AnswerRe: related to crystal report Pin
karthiknss29-Oct-09 22:42
karthiknss29-Oct-09 22:42 
GeneralRe: related to crystal report Pin
NarendraSinghJTV1-Nov-09 23:06
NarendraSinghJTV1-Nov-09 23:06 
QuestionNULLABLE type Pin
RINSON VARGHESE28-Oct-09 2:48
RINSON VARGHESE28-Oct-09 2:48 
AnswerRe: NULLABLE type Pin
Keith Barrow28-Oct-09 2:55
professionalKeith Barrow28-Oct-09 2:55 
AnswerRe: NULLABLE type Pin
Abhishek Sur28-Oct-09 3:31
professionalAbhishek Sur28-Oct-09 3:31 
AnswerRe: NULLABLE type Pin
Keith Barrow28-Oct-09 4:17
professionalKeith Barrow28-Oct-09 4:17 
OK, so my facecious comment wasn't so helpful.

Primitive types (int, bool etc) are not nullable, the classic exception to this is string, which can be set to null.

Objects of type object and derived from object are nullable. Nullable types allow null values on "primitive" types (they also have HasValue property):

i.e.

int foo = null; //Design time/ compile time error : assigning null to non-nullable primative type
int? bar = null; //OK
string baz = null; //OK, string is nullable.
string? quux = null; //Design time / compile time error : string is nullable
Nullable<string> foo1 = null; //Design time/ compile time error : string is nullable
object bar1 = null; //OK: Object nullable
MyClass baz1 = null; //OK: Object nullable as is an object.


Personally, I'd stear clear of nullable values where possible, as you will need to perpetually check the value is not null and other types of evil ensue.

CCC solved so far: 2 (including a Hard One!)

GeneralRe: NULLABLE type Pin
Abhishek Sur28-Oct-09 5:13
professionalAbhishek Sur28-Oct-09 5:13 
GeneralRe: NULLABLE type Pin
vtchris-peterson28-Oct-09 5:34
vtchris-peterson28-Oct-09 5:34 
GeneralRe: NULLABLE type Pin
Keith Barrow28-Oct-09 5:56
professionalKeith Barrow28-Oct-09 5:56 
GeneralRe: NULLABLE type Pin
Rick Shaub28-Oct-09 8:11
Rick Shaub28-Oct-09 8:11 
GeneralRe: NULLABLE type Pin
Keith Barrow28-Oct-09 14:38
professionalKeith Barrow28-Oct-09 14:38 
GeneralRe: NULLABLE type Pin
vtchris-peterson28-Oct-09 10:02
vtchris-peterson28-Oct-09 10:02 
GeneralRe: NULLABLE type Pin
Keith Barrow28-Oct-09 14:25
professionalKeith Barrow28-Oct-09 14:25 
GeneralRe: NULLABLE type Pin
vtchris-peterson28-Oct-09 14:53
vtchris-peterson28-Oct-09 14:53 
GeneralRe: NULLABLE type Pin
Keith Barrow29-Oct-09 0:17
professionalKeith Barrow29-Oct-09 0:17 
GeneralRe: NULLABLE type Pin
vtchris-peterson29-Oct-09 4:10
vtchris-peterson29-Oct-09 4:10 
GeneralRe: NULLABLE type Pin
Keith Barrow29-Oct-09 5:14
professionalKeith Barrow29-Oct-09 5:14 
GeneralRe: NULLABLE type Pin
Mycroft Holmes28-Oct-09 14:53
professionalMycroft Holmes28-Oct-09 14:53 
GeneralRe: NULLABLE type Pin
Keith Barrow29-Oct-09 0:20
professionalKeith Barrow29-Oct-09 0:20 
QuestionOutlining option is not coming on right clicking in text Pin
abcurl28-Oct-09 2:19
abcurl28-Oct-09 2:19 
AnswerRe: Outlining option is not coming on right clicking in text Pin
Abhishek Sur28-Oct-09 3:31
professionalAbhishek Sur28-Oct-09 3:31 
AnswerRe: Outlining option is not coming on right clicking in text Pin
Richard MacCutchan28-Oct-09 4:02
mveRichard MacCutchan28-Oct-09 4:02 
QuestionRe: Outlining option is not coming on right clicking in text Pin
abcurl28-Oct-09 4:19
abcurl28-Oct-09 4:19 

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.