problem passing parameter from controlP5 Textfield method
              in 
             Contributed Library Questions 
              •  
              1 year ago    
            
 
           
             I am trying to pass the value of a ControlP5 Textfield out of the user-named method to get the value to a class method but i am getting this error: 
            
             
            
            
             
              
            
            
             
            
            
             
              
             
             
            
             
             
           
 
            
           - Jan 21, 2012 3:02:03 PM controlP5.ControlBroadcaster printMethodError
- SEVERE: An error occured while forwarding a Controller value
- to a method in your program. Please check your code for any
- possible errors that might occur in this method .
- e.g. check for casting errors, possible nullpointers, array overflows ... .
- method: inputField
- exception: java.lang.reflect.InvocationTargetException
               and here is the code i am using:  
              
             - ControlP5 gui;
- gui = new ControlP5(this);
- String consoleText;
- Textfield inputField;
- inputField = gui.addTextfield("inputField", 0, height-26, width-1, 25);
- inputField.keepFocus(true);
- public void inputField(String textFieldInput) {
- commit(textFieldInput);
- }
- public void commit(String input){
- consoleText.concat(input);
- }
              I am  creating a Textfield called inputField, then instantiating it in my gui, then all i want is to pass the confirmed text (when you type then hit 'Enter') from inputField to my method that adds it to a string so i can display it in a Textarea.
             
             
              not sure what the problem is exactly, there isn't a whole lot of code there for me to screw up. I found a couple others with this same error but they were dealing with multiples in a dropdownlist. any help would be great. thanks
             
             
              
              1  
            
 
            
 
 
          