Hello, I'm new to the world of VB. I have VB Express 2008 and I have been working on a simple dice rolling windows app.

The app works but the form controls get displaced from where they are in the designer window to where they are after a test build is executed. I would have text fields, buttons and labels setup in a orderly fashion only to have them stacked on each other and moved to the wrong places after I build.

It also seems like its showing me an old copy of my file? Is there a preference thats not overwriting my files upon build correctly?

Any suggestions would be of great help.

Hey, make sure you save your project before building. If that doesn't fix it, then go to design view, and select your controls, and under "Properties" section, try changing "Locked" to "True". That should prevent them from being moved. Then save, and build your project, and it should work.

Thanks for the response! I went ahead and followed your suggestions. I loaded my project, did Save All, Then locked all controls. I could see the little black lock icons on everything. Then I went and clicked the green arrow button for start debugging.

the app appears with all controls but the first set of controls that I have at the top of my form are still moved.

I have 3 form controls for each type of die in my dice roller game. The first set is for a four sided die.

the Textbox which contains the text '0' is first for the number of dice to be rolled..and that gets moved, then there is a button to press to 'roll' the dice. Finally there is a label that follows that contains only a "-" until results are given after rolling.

That label gets smashed up against the button every time I debug. This happens even if I move the controls to different places on the form... It seems like its ignoring my current saved project and building a different one, but I havent changed any settings in VB Express that I'm aware of.

** Okay I Just tried to continue with the project and I added a background image for one of the dice buttons..it appears in my project, I save all, I start debug..and the image isn't there! Again, I don't think its compiling the right project...

OK, I'm out of ideas, lol. Only one other thing I can think of is maybe some controls are misnamed or misspelled. You could always try starting over and see if you get the same errors :P

OK, I'm out of ideas, lol. Only one other thing I can think of is maybe some controls are misnamed or misspelled. You could always try starting over and see if you get the same errors :P

Ya makes no sense to me either. I am uninstalling all my IDEs and reinstalling just Visual Basic Express 2008 and putting my bin folder back and loading and rebuilding the project and see if it happens again...

The names are all generic btw, button1, label1 etc...so I dont get it..I checked the code for anything outside the norm...this is really simmple stuff... I will report back either way after the reinstall

Thanks again

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.