private void buttonSearchActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_buttonSearchActionPerformed

        String searchQuery = textSearch.getText().toUpperCase();
        
        String agcoopCompany = "maininterface.ViewCompany";
        String agcoopMember = "maininterface.ViewMember";
        String agcoopSupplier = "maininterface.ViewSupplier";
        String agcoopNonMember = "maininterface.ViewNonMember";
        
        try{
            if(viewTab.getSelectedComponent().getClass().getName().equals(agcoopCompany))
            {
                vC.getList(1, searchQuery);
            }
        
            else if(viewTab.getSelectedComponent().getClass().getName().equals(agcoopMember))
            {
                vM.getList(1, searchQuery);
            }
        
            else if(viewTab.getSelectedComponent().getClass().getName().equals(agcoopSupplier))
            {
                vS.getList(1, searchQuery);
            }
            else if(viewTab.getSelectedComponent().getClass().getName().equals(agcoopNonMember))
            {
                vNM.getList(1, searchQuery);
            }                  
        }
        catch(Exception e) { }
        
        
        // TODO add your handling code here:
    }//GEN-LAST:event_buttonSearchActionPerformed