Results 1 to 6 of 6
- 05-01-2009, 05:15 PM #1
[SOLVED] Turn off NetBeans code blocker
I'm curious if there's a setting I can uncheck within netbeans to allow me to alter the generated code that gets created when using the GUI creator? It's fine for laying out everything but when it comes time to work the backbones in I want to be able to do that myself.
Liberty has never come from the government.
Liberty has always come from the subjects of government.
The history of liberty is the history of resistance.
The history of liberty is a history of the limitation of governmental power, not the increase of it.
- 05-01-2009, 05:49 PM #2
I don't think that you can turn it off... But I did some playing around and if you go into the directory where the source files are, there will be a xml file there... If you simply rename that file, close your class and reopen it, NetBeans will treat it like a normal class... Then if you want to put it back into the GUI Builder, just change the name back...
The syntax of the xml file will be YourClassName.form...Last edited by markw8500; 05-01-2009 at 05:58 PM.
Who Cares... As Long As It Works...
- 05-01-2009, 07:38 PM #3
Member
- Join Date
- Nov 2008
- Posts
- 42
- Rep Power
- 0
You can just do the coding that you didn't want to be generated in another method. For example :
Something wrong with that?Java Code:public class TestFrame extends javax.swing.JFrame { /** Creates new form TestFrame */ public TestFrame() { initComponents(); //Generated code initComponents2(); //Your code } }
- 05-01-2009, 07:55 PM #4
actually I found this cool little customize code button that lets me put a method call right where I declare one of the Swing components and from that method I can easily manipulate that piece.(Essentially what Gudradain said except I needed to know how to put the method call in there to begin with)
Liberty has never come from the government.
Liberty has always come from the subjects of government.
The history of liberty is the history of resistance.
The history of liberty is a history of the limitation of governmental power, not the increase of it.
- 05-02-2009, 06:11 AM #5
Member
- Join Date
- Nov 2008
- Posts
- 42
- Rep Power
- 0
Hmmm, I don't really like the customize code button. Why? You only get error message when you look at the generated code in the source (you don't get them while you are typing in the customize code). Also, if you want something on one component you have to open the customize code for this component specifically. Might be a waste of time if you just have to change a little something on many components.
- 05-04-2009, 05:07 PM #6
That's exactly how I felt but for simple stuff that I shouldn't really be getting confusing errors on it works. I can just copy the generated code into eclipse for the more complex stuff.
Liberty has never come from the government.
Liberty has always come from the subjects of government.
The history of liberty is the history of resistance.
The history of liberty is a history of the limitation of governmental power, not the increase of it.
Similar Threads
-
help with calling jasper reports from java code (am using netbeans)
By sj_1188 in forum NetBeansReplies: 9Last Post: 12-21-2010, 02:37 PM -
Turn off sounds in Eclipse
By gio.fou in forum EclipseReplies: 2Last Post: 09-06-2008, 08:31 PM -
whats the code that we need to connect oracle10g with the netbeans
By katko0ota in forum Enterprise JavaBeans (EJB)Replies: 6Last Post: 07-15-2008, 05:52 PM -
turn off auto compile
By bugger in forum EclipseReplies: 3Last Post: 01-04-2008, 08:12 PM -
Netbeans 6.0 - code completion of method parameters
By mwildam in forum NetBeansReplies: 9Last Post: 12-18-2007, 09:02 AM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks