Click here to Skip to main content
15,903,854 members
Home / Discussions / C#
   

C#

 
GeneralRe: Cookie Pin
Moon Boy5-Jul-04 19:07
Moon Boy5-Jul-04 19:07 
GeneralRe: Cookie Pin
Heath Stewart5-Jul-04 19:09
protectorHeath Stewart5-Jul-04 19:09 
GeneralRe: Cookie Pin
Moon Boy5-Jul-04 19:16
Moon Boy5-Jul-04 19:16 
QuestionHow to add Textbox's PasswordChar property in PropertyGrid Control? Pin
god4k5-Jul-04 15:48
god4k5-Jul-04 15:48 
AnswerRe: How to add Textbox's PasswordChar property in PropertyGrid Control? Pin
Heath Stewart5-Jul-04 18:17
protectorHeath Stewart5-Jul-04 18:17 
GeneralRe: How to add Textbox's PasswordChar property in PropertyGrid Control? Pin
god4k5-Jul-04 18:42
god4k5-Jul-04 18:42 
GeneralQuick bit field question Pin
benglish725-Jul-04 13:28
benglish725-Jul-04 13:28 
GeneralRe: Quick bit field question Pin
Mike Dimmick5-Jul-04 13:38
Mike Dimmick5-Jul-04 13:38 
It's the other way round: the if statement requires the condition to evaluate to type bool in C#. You can't simply test an integer.

If enum.value represents a single flag, use
if( ( flag.value & enum.value ) == enum.value )
{
}
If it represents a mask of flags, and you want to know if any of the masked flags are set, use
if( ( flag.value & enum.value ) != 0 )
{
}
You might need to add the FlagsAttribute to your enum for the latter to work.

Stability. What an interesting concept. -- Chris Maunder
GeneralRe: Quick bit field question Pin
benglish725-Jul-04 15:12
benglish725-Jul-04 15:12 
QuestionSQL Security Hole - am I vulnerable? Pin
Ian Bowler5-Jul-04 13:04
Ian Bowler5-Jul-04 13:04 
AnswerRe: SQL Security Hole - am I vulnerable? Pin
Mike Dimmick5-Jul-04 13:33
Mike Dimmick5-Jul-04 13:33 
GeneralRe: SQL Security Hole - am I vulnerable? Pin
Ian Bowler5-Jul-04 21:32
Ian Bowler5-Jul-04 21:32 
GeneralRe: SQL Security Hole - am I vulnerable? Pin
Colin Angus Mackay5-Jul-04 23:25
Colin Angus Mackay5-Jul-04 23:25 
Generalcomparison of two strings - how to get a score Pin
rlacatus5-Jul-04 12:34
rlacatus5-Jul-04 12:34 
GeneralRe: comparison of two strings - how to get a score Pin
rlacatus6-Jul-04 11:30
rlacatus6-Jul-04 11:30 
GeneralDataGrid current row Pin
Christian Graus5-Jul-04 11:13
protectorChristian Graus5-Jul-04 11:13 
GeneralRe: DataGrid current row Pin
Christian Graus5-Jul-04 12:14
protectorChristian Graus5-Jul-04 12:14 
GeneralRe: DataGrid current row Pin
Heath Stewart5-Jul-04 18:08
protectorHeath Stewart5-Jul-04 18:08 
GeneralRe: DataGrid current row Pin
sreejith ss nair6-Jul-04 2:03
sreejith ss nair6-Jul-04 2:03 
GeneralAccessing Data with Web Forms Pin
Ian Bowler5-Jul-04 10:38
Ian Bowler5-Jul-04 10:38 
GeneralRe: Accessing Data with Web Forms Pin
Colin Angus Mackay5-Jul-04 11:13
Colin Angus Mackay5-Jul-04 11:13 
GeneralRe: Accessing Data with Web Forms Pin
Ian Bowler5-Jul-04 11:41
Ian Bowler5-Jul-04 11:41 
GeneralRe: Accessing Data with Web Forms Pin
Colin Angus Mackay5-Jul-04 11:56
Colin Angus Mackay5-Jul-04 11:56 
GeneralRe: Accessing Data with Web Forms Pin
Ian Bowler5-Jul-04 12:03
Ian Bowler5-Jul-04 12:03 
GeneralRe: Accessing Data with Web Forms Pin
Colin Angus Mackay5-Jul-04 12:22
Colin Angus Mackay5-Jul-04 12:22 

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.