Netbeans GUI Form corrupted?

I was making a java gui application through netbeans IDE. All was working fine but yesterday when I opened the form in Netbeans, it said that the form had been corrupted and it could only open that form in read-only mode.

When I opened that form in read-only mode, I found that the code was incomplete as severals lines of coding wasn't there at the end.

Could anybody tell me how to recover the form. The form is perfect in lookwise but the generated code is incomplete.

The code is too long to write it again.

The Netbeans told me to get help from http://wiki.netbeans.org/FormGuardedBlockError but I didn't find any helpful information there.

Answers


Have you tried select all on the readonly form, copy and paste to a new form? That might regenerate your lost code.

btw, this is exactly the kind of common scenario programmers hedge against when they write code. i have used half a dozen UI designers at least and they have ALL given me this problem. But since i use SVN all i had to do was delete the corruption and do and update... all my lost work came back.


I run into this at times and it drives me crazy. Often the issue isn't in the complaining form, but a dependency used by that form!

The most common gotcha that I see is when form dependencies (other forms being used by a bigger form) throw exceptions within the GUI builder. Remember, NetBeans is instantiating the forms when used by other forms, it usually invokes a parameterless constructor.

If the parameterless constructor in a sub form throws an exception, you may not know about it until your master form is instantiated (depending on what you do with the subform from your master form code).

I know that's a bit wordy, but I hope it helps!


I have a same problem, It seems the only way is using Restore From SVN/CVS/LocalHistory !!! That's so bad :(


I got the same problem and I fixed it . I hope it works

I fixed it by Click --> team(At menubar netbean) --> History --> show History and then you 'll see your last version that doesn't contain the problem , finally you click right and reverse to previous vision .


Need Your Help

iCloud Documents not visible

ios objective-c xcode icloud uidocument

I am trying to use iCloud Documents to store XML files from my iOS App. Everything seems to be working fine (I can write and read files without errors) except my App's files do not show up in iCloud

Saving images names with their sizes to a file in Windows

windows excel image text save

In Windows, I have a folder ImageDir with images inside it. I want to save all the images names with their sizes in a text file or excel file.