Click here to Skip to main content
15,886,689 members
Home / Discussions / C#
   

C#

 
GeneralDatabase, ODP.NET, ADODC Pin
CyberKewl13-Aug-03 14:28
CyberKewl13-Aug-03 14:28 
GeneralRe: Database, ODP.NET, ADODC Pin
Ista13-Aug-03 15:24
Ista13-Aug-03 15:24 
GeneralONE CLICK Pin
eggie513-Aug-03 13:34
eggie513-Aug-03 13:34 
GeneralRe: ONE CLICK Pin
Alvaro Mendez13-Aug-03 14:14
Alvaro Mendez13-Aug-03 14:14 
GeneralRe: ONE CLICK Pin
Furty13-Aug-03 14:21
Furty13-Aug-03 14:21 
GeneralRe: ONE CLICK Pin
eggie513-Aug-03 14:34
eggie513-Aug-03 14:34 
GeneralRe: ONE CLICK Pin
eggie513-Aug-03 17:00
eggie513-Aug-03 17:00 
GeneralRe: ONE CLICK Pin
Rocky Moore13-Aug-03 14:31
Rocky Moore13-Aug-03 14:31 
Is your btn.Text initailly set to "1"? You have the initial value of switchMC as true, so the first time through it will go through the "True" condition and the next time it will go through the "False" condition.

Also, you do not need the second "IF" since you are using an ELSE, the ELSE will only be reached if switchMC is not true so you do not need the addition test. You could also restructure the code to either:

Button btn = (Button) sender;			
if(switchMC)			
{	
   btn.Text="1";				
   switchMC=false;			
}			
else 
{		
   btn.Text="0";				
   switchMC=true;			
}


Or

Button btn = (Button) sender;
btn.Text = switchMC ? "1" : "0";
switchMC=!switchMC;


Rocky Moore <><
GeneralRe: ONE CLICK Pin
eggie513-Aug-03 16:38
eggie513-Aug-03 16:38 
GeneralRe: ONE CLICK Pin
Rocky Moore13-Aug-03 21:29
Rocky Moore13-Aug-03 21:29 
GeneralRe: ONE CLICK Pin
eggie513-Aug-03 21:35
eggie513-Aug-03 21:35 
GeneralRe: ONE CLICK Pin
Ista13-Aug-03 15:27
Ista13-Aug-03 15:27 
GeneralHey whats THE CODE to cal the MAIN thread Pin
Ista13-Aug-03 13:33
Ista13-Aug-03 13:33 
GeneralRe: Hey whats THE CODE to cal the MAIN thread Pin
Furty13-Aug-03 14:24
Furty13-Aug-03 14:24 
GeneralRe: Hey whats THE CODE to cal the MAIN thread Pin
Ista13-Aug-03 15:23
Ista13-Aug-03 15:23 
GeneralSort Array Pin
Mazdak13-Aug-03 9:26
Mazdak13-Aug-03 9:26 
GeneralRe: Sort Array Pin
Ista13-Aug-03 13:27
Ista13-Aug-03 13:27 
GeneralKeyDown for arrows Pin
S O S13-Aug-03 6:23
S O S13-Aug-03 6:23 
GeneralRe: KeyDown for arrows Pin
Nnamdi Onyeyiri13-Aug-03 7:17
Nnamdi Onyeyiri13-Aug-03 7:17 
GeneralRe: KeyDown for arrows Pin
S O S13-Aug-03 8:27
S O S13-Aug-03 8:27 
GeneralRe: KeyDown for arrows Pin
Nnamdi Onyeyiri13-Aug-03 8:40
Nnamdi Onyeyiri13-Aug-03 8:40 
GeneralRe: KeyDown for arrows Pin
Ista13-Aug-03 13:19
Ista13-Aug-03 13:19 
GeneralRe: KeyDown for arrows Pin
Ista13-Aug-03 13:21
Ista13-Aug-03 13:21 
Generaldatagrid Pin
mdolby13-Aug-03 5:26
mdolby13-Aug-03 5:26 
GeneralRe: datagrid Pin
Ista13-Aug-03 13:24
Ista13-Aug-03 13:24 

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.