Hi ,
I am pretty new to c# .I am trying to create a checkbox group ,when check box checked ,it has to strike off the text next to it ,with uncheck it as to undo the strike.
Please urgent...need help with code.....ASAP.
Thanks,
Chin-
Loading
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Scott LyslePosted Apr 30, 2007, 3:05 PM
To handle the issue of striking out the checkbox label, this will do it:
private
void checkBox1_CheckedChanged(object sender, EventArgs e){
Font startFont = checkBox1.Font;
checkBox1.Font = new Font(startFont, startFont.Style ^ FontStyle.Strikeout);
}