We've been having problems similar to the image shown in this post. They tend to happen while we are drawing in windows or subsurfaces. Sometimes when we save and close, then reopen the file, windows and walls are misplaced, inverted, or simply missing.
By sheer rote, we realized that we can avoid this problem by double clicking out of a space before double clicking into the next space:
When drawing the windows, it is necessary to double-click to select the space, otherwise you will just be drawing a SketchUp surface. In order to save time, we were double-clicking on the next space we wanted to draw a window in while the previous space was still selected. I noticed that after operations where we were doing this frequently, the wall flying problem almost always occurred, so I tried double-clicking out of the space between each space change.
Since implementing this method we have had no issues with flying walls.
Unfortunately I cannot offer insight into how to repair a file which has flown walls. We've been keeping backups of our file every 15 minutes or so because when something goes wrong, we usually cannot fix it. You'll have to go back to the file without the windows and remember to deselect the space you have selected before selecting the next space.
Which software are you using?
I am using SketchUp Openstudio Plug-in
Can you provide a few more details on how you are creating the windows, and what specifically is happening. Are the windows floating instead of attached to the base surfaces, or is it something else? Also does this happen immediately, or after you close and re-open the model.
Before I re-open the model, everything looks good. But after I re-opened it, the walls were everywhere. This issue only happens on those surfaces which I added the windows.
Does the error dialog show anything? You may also want to try the diagnostic script. A screen shot may still help to understand where the surfaces are going.