Control properties say 1 thing but control visuals say another

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a problem that I cannot figure out. I have a number of controls (list
boxes, radio buttons, text boxes, etc) that are not functioning properly.
The properties of each control are set (via code) but they are not being
updated in the form that contains them. The opposite is true as well (if I
change a control in the form, the controls are not updated). Here are a few
examples

-I set ButtonA to invisible (visible = false) but ButtonA remains visible.
When I click a different button (where I have a break point inserted), I see
that ButtonA.Visible is still false.

-I fill a listbox with items. When I run the form, the listbox is empty but
when I check out the list box at my breakpoint, I see that it is full of items

-I click a radio button. When I look at the radiobutton at my breakpoint, I
see that the property checked is still false even though it is clicked on the
interface.

The list goes on. The project is a windows project in visual studio 2003.
I first noticed this problem after I installed VS 2003 sp 1. When I checked
out the issue with just VS 2003 (no sp 1) the problem was still present. So,
it doesn't appear like an sp 1 issue.

Any ideas? I'm stuck on this one.
 
Ok, I deleted both the obj and bin directories but my problem was not solved.

I did manage to find a work around for the problem. The problem was
occurring in one form. So, I created a copy of the form that was causing me
problems and then overwrote the original with a form from an earlier back up.
I then copied all the new functional code (a couple properties and some
minor function changes) to update the back up version to the current version.
This corrected my problem but still leaves me wondering what the real issue
code be.

I don't see how the code and binary could be in a different stat since I
deleted both the obj and bin dirs. I'm thinking that somehow, the VS
designer code (InitializeComponents(),etc) was somehow affected by something.
But I still am clueless on the whole situation. Hopefully I will never see
it again.
 
Back
Top