In IDE: NetBeans: i am having issue in calling new form after performing an 
action. Below is the line of code
protected void onFindTrans_FindGetButtonAction(Component c, ActionEvent 
event) {
        final String findName =  
findFindTranNameComboBox(c.getComponentForm()).getSelectedItem().toString();
        final String findPort =  
findFindTranPortComboBox(c.getComponentForm()).getSelectedItem().toString();
        final String findSour =  
findFindSourceTextField(c.getComponentForm()).getText();
        final String findDest =  
findFindDestinateTextField(c.getComponentForm()).getText();
        final String findStat =  
findFindStationTextField(c.getComponentForm()).getText(); 
        final String findDate =  
findFindDatePicker(c.getComponentForm()).getText();
        final Boolean findCheck = 
(Boolean)findFindCheckBox(c.getComponentForm()).isSelected();
        if (("".equals(findName)) || ("".equals(findPort)) || 
("".equals(findSour)) || ("".equals(findDest)) || ("".equals(findDate))) {
           Dialog.show("Error", "All fields are required", "OK", null); 
        }
        else{
            if(findFindCheckBox(c.getComponentForm()).isSelected()){
                if(!"".equals(findStat)){
                       
                        finCheck = "TRUE";
                        
findTran(findName,findPort,findSour,findDest,findStat,findDate,finCheck);
                        showForm("Main", null);
                } else {
                       
                        finCheck = "TRUE";
                        finStat  = "NONE";
                        
findTran(findName,findPort,findSour,findDest,finStat,findDate,finCheck);
                        showForm("Main", null);
                }
            }else{
                if(!findFindCheckBox(c.getComponentForm()).isSelected()){
                    if(!"".equals(findStat)){                        
                        finCheck = "FALSE";
                        
findTran(findName,findPort,findSour,findDest,findStat,findDate,finCheck);
                        showForm("Main", null);
                } else {
                    finCheck = "FALSE";
                    finStat  = "NONE";
                    
findTran(findName,findPort,findSour,findDest,finStat,findDate,finCheck);
                    showForm("Main", null);
                }
                }
            }
        }
        
    }

-- 
You received this message because you are subscribed to the Google Groups 
"CodenameOne Discussions" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to codenameone-discussions+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/codenameone-discussions.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/codenameone-discussions/82750e27-8b5a-4bf3-974c-75e77560bbe6%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to