|
-
Oct 3rd, 2010, 06:19 AM
#1
Thread Starter
Hyperactive Member
My CheckBox always believes it is unchecked !
I have a very stubborn check box . Let me tell you its story :
There is Form1 with a button leading to Form2 . On Form2 there is located that stubborn check box I was telling you about . That check box has code in its CheckedChange event and accordingly to its Checked condition , it enables or disables some text boxes .
Well , the first time Form2 is shown , that check box works fine : when I check it it enambles the text boxes and when I uncheck it , it disables those text boxes .
Then , I press the button to return to Form1 . If needed , the code in the button is :
Form1.Show
Me.Close
My adventure starts when I show again Form2 ... This time the check box is acting weirdly . No matter if I check it or I uncheck it , it always disables the text boxes , as if it is constantly unchecked ! I can see it changing its checked state whenever I click on it , but it always runs the code to disable the text boxes ...
I even used some break points in the code and found out that indeed it is the code that disables the text boxes that is called every time , no matter if the check box is checked or unchecked .
I don't thing this has anything to do with the fact that this event is called by all the 4 check boxes on the form . After all , it is always the 1st check box that causes the problem (I can see it when moving the cursor over the genericindex variable) .
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|