aspose file tools*
The moose likes IDEs, Version Control and other tools and the fly likes NetBeans editing auto generated code... Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Engineering » IDEs, Version Control and other tools
Bookmark "NetBeans editing auto generated code..." Watch "NetBeans editing auto generated code..." New topic
Author

NetBeans editing auto generated code...

Tad Dicks
Ranch Hand

Joined: Nov 16, 2004
Posts: 264
I'm working on a project and someone built the main gui interface using the form generator in NetBeans.

All of the autogenerated code is highlighted blue and "locked" is there a way in net beans to unlock it? so I can make changes to it?


-Tad
Jeroen Wenting
Ranch Hand

Joined: Oct 12, 2000
Posts: 5093
no. And don't think of editing the code outside Netbeans as Netbeans is apt to undo whatever you changed the next time you load the class inside Netbeans.

The only solution is to switch to an IDE that doesn't have such restrictions.
[ March 20, 2005: Message edited by: Jeanne Boyarsky ]

42
C Kutler
Ranch Hand

Joined: Apr 15, 2004
Posts: 62
Actually, the answer is YES. Simply look for and delete all the .form files associated with that project.

While it is true that the IDE does not reverse engineer user written code so that you can use the GUI builder, edit in a different editor or IDE, and then use the GUI builder again, you can use the GUI builder to quickly build and maintain the interface. Should you choose at any time to use something besides the GUI builder, disconnect the code from the builder by removing the .form metadata files.


We learn by doing, there is no other way.
C Kutler
Ranch Hand

Joined: Apr 15, 2004
Posts: 62
Another method is to simply copy the generated code and paste it back
into the source code without the code that signifies the beginning and
end of the guarded block.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: NetBeans editing auto generated code...
 
Similar Threads
how to change the generated code by IDE (netbeans)
Netbeans
Code Behind The Scenes
Help Please: Getting package does not exist for "javax.ejb.*"
netbeans vs eclipse