Examples of JLabel4j_std


Examples of com.commander4j.gui.JLabel4j_std

            }
          });
        }

        {
          lblSampleID = new JLabel4j_std();
          jDesktopPane1.add(lblSampleID);
          lblSampleID.setText(lang.get("lbl_SampleID"));
          lblSampleID.setBounds(7, 14, 133, 21);
          lblSampleID.setHorizontalAlignment(SwingConstants.TRAILING);
        }
        {
          lblUserData2 = new JLabel4j_std();
          jDesktopPane1.add(lblUserData2);
          lblUserData2.setBounds(7, 250, 133, 21);
          lblUserData2.setHorizontalAlignment(SwingConstants.TRAILING);
          lblUserData2.setText(lang.get("lbl_User_Data2"));
        }

        {
          lblMaterial = new JLabel4j_std();
          jDesktopPane1.add(lblMaterial);
          lblMaterial.setText(lang.get("lbl_Material"));
          lblMaterial.setHorizontalAlignment(SwingConstants.TRAILING);
          lblMaterial.setBounds(7, 118, 133, 21);
        }
        {
          jTextFieldMaterial = new JTextField4j();
          jDesktopPane1.add(jTextFieldMaterial);
          jTextFieldMaterial.setBounds(147, 116, 119, 21);
          jTextFieldMaterial.setEnabled(false);
        }
        {
          lblActivityID = new JLabel4j_std();
          jDesktopPane1.add(lblActivityID);
          lblActivityID.setText(lang.get("lbl_Activity_ID"));
          lblActivityID.setHorizontalAlignment(SwingConstants.TRAILING);
          lblActivityID.setBounds(7, 196, 133, 21);
        }
        {
          jTextFieldActivityID = new JTextField4j();
          jDesktopPane1.add(jTextFieldActivityID);
          jTextFieldActivityID.setBounds(147, 194, 119, 21);
          jTextFieldActivityID.setEnabled(false);
        }

        {
          lblProcessOrder = new JLabel4j_std();
          jDesktopPane1.add(lblProcessOrder);
          lblProcessOrder.setText(lang.get("lbl_Process_Order"));
          lblProcessOrder.setHorizontalAlignment(SwingConstants.TRAILING);
          lblProcessOrder.setBounds(7, 66, 133, 21);
        }
        {
          jTextFieldProcessOrder = new JTextField4j();
          jDesktopPane1.add(jTextFieldProcessOrder);
          jTextFieldProcessOrder.setBounds(147, 64, 119, 21);
          jTextFieldProcessOrder.setEnabled(false);

        }
        {
          jTextFieldUserData2 = new JTextField4j();
          jDesktopPane1.add(jTextFieldUserData2);
          jTextFieldUserData2.setBounds(147, 246, 119, 21);
          jTextFieldUserData2.setFocusCycleRoot(true);
        }
        {
          lblUserData1 = new JLabel4j_std();
          jDesktopPane1.add(lblUserData1);
          lblUserData1.setText(lang.get("lbl_User_Data1"));
          lblUserData1.setHorizontalAlignment(SwingConstants.TRAILING);
          lblUserData1.setBounds(7, 224, 133, 21);
        }

        {
          jTextFieldProcessOrderDescription = new JTextField4j();
          jDesktopPane1.add(jTextFieldProcessOrderDescription);
          jTextFieldProcessOrderDescription.setBounds(147, 90, 287, 21);
          jTextFieldProcessOrderDescription.setEnabled(false);
        }
        {
          lblProcessOrderDescription = new JLabel4j_std();
          jDesktopPane1.add(lblProcessOrderDescription);
          lblProcessOrderDescription.setText(lang.get("lbl_Description"));
          lblProcessOrderDescription.setHorizontalAlignment(SwingConstants.TRAILING);
          lblProcessOrderDescription.setBounds(7, 92, 133, 21);
        }
        {
          lblMaterialDescription = new JLabel4j_std();
          jDesktopPane1.add(lblMaterialDescription);
          lblMaterialDescription.setText(lang.get("lbl_Description"));
          lblMaterialDescription.setHorizontalAlignment(SwingConstants.TRAILING);
          lblMaterialDescription.setBounds(7, 144, 133, 21);
        }
        {
          jTextFieldMaterialDescription = new JTextField4j();
          jDesktopPane1.add(jTextFieldMaterialDescription);
          jTextFieldMaterialDescription.setBounds(147, 142, 287, 21);
          jTextFieldMaterialDescription.setEnabled(false);

        }
        {
          jStatusText = new JLabel4j_std();
          jDesktopPane1.add(jStatusText);
          jStatusText.setForeground(new java.awt.Color(255, 0, 0));
          jStatusText.setBorder(BorderFactory.createBevelBorder(BevelBorder.LOWERED));
          jStatusText.setBounds(0, 373, 510, 21);
        }

        {
          jTextFieldUserData1 = new JTextField4j();
          jTextFieldUserData1.setFocusCycleRoot(true);
          jTextFieldUserData1.setBounds(147, 220, 119, 21);
          jDesktopPane1.add(jTextFieldUserData1);
        }

        {
          lblInspectionID = new JLabel4j_std();
          lblInspectionID.setHorizontalAlignment(SwingConstants.TRAILING);
          lblInspectionID.setText(lang.get("lbl_Location_ID"));
          lblInspectionID.setBounds(7, 170, 133, 21);
          jDesktopPane1.add(lblInspectionID);
        }

        {
          jTextFieldInspectionID = new JTextField4j();
          jTextFieldInspectionID.setBounds(147, 168, 119, 21);
          jTextFieldInspectionID.setEnabled(false);
          jDesktopPane1.add(jTextFieldInspectionID);
        }
       
        {
          JLabel4j_std lblSampleDate = new JLabel4j_std();
          lblSampleDate.setText(lang.get("lbl_Sample_Date"));
          lblSampleDate.setHorizontalAlignment(SwingConstants.TRAILING);
          lblSampleDate.setBounds(7, 40, 133, 21);
          jDesktopPane1.add(lblSampleDate);
        }
       
        {
          sampleDate = new JDateControl();
          jDesktopPane1.add(sampleDate);
          sampleDate.setBounds(147, 36, 125, 25);
          sampleDate.getEditor().setPreferredSize(new java.awt.Dimension(87, 19));
          sampleDate.getEditor().setSize(87, 21);
        }
        {
          JButton4j btnPrint = new JButton4j(Common.icon_print);
          btnPrint.setText(lang.get("btn_Print"));
          btnPrint.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
              updateRecord();
              Long sampleID = sample.generateSampleID();
              String pq = comboBoxPrintQueue.getSelectedItem().toString();
              buildSQL1Record(sampleID);
              JLaunchReport.runReport("RPT_SAMPLE_LABEL", listStatement, false, pq, Integer.valueOf(spinnerCopies.getValue().toString()), false);
              jStatusText.setText(Integer.valueOf(spinnerCopies.getValue().toString()) + " labels printed. " + sample.getSampleDate().toString());
            }
          });
          btnPrint.setMnemonic('0');
          btnPrint.setEnabled(true);
          btnPrint.setBounds(212, 333, 100, 28);
          jDesktopPane1.add(btnPrint);
        }
       
        comboBoxPrintQueue.setBounds(145, 272, 365, 25);
        jDesktopPane1.add(comboBoxPrintQueue);
       
        {
          JLabel4j_std lblNewLabel_5 = new JLabel4j_std(lang.get("lbl_Number_Of_Labels"));
          lblNewLabel_5.setHorizontalAlignment(SwingConstants.TRAILING);
          lblNewLabel_5.setBounds(6, 442, 138, 16);
          jDesktopPane1.add(lblNewLabel_5);
        }
       
        {
          spinnerCopies = new JSpinner();
          spinnerCopies.setBounds(149, 300, 37, 28);
          JSpinner.NumberEditor ne = new JSpinner.NumberEditor(spinnerCopies);
          ne.getTextField().setFont(Common.font_std);
          spinnerCopies.setEditor(ne);
          jDesktopPane1.add(spinnerCopies);         
        }
       
        JLabel4j_std label4j_std = new JLabel4j_std(lang.get("lbl_Print_Queue"));
        label4j_std.setHorizontalAlignment(SwingConstants.TRAILING);
        label4j_std.setBounds(0, 278, 138, 16);
        jDesktopPane1.add(label4j_std);
       
        JLabel4j_std label4j_std_1 = new JLabel4j_std(lang.get("lbl_Number_Of_Labels"));
        label4j_std_1.setHorizontalAlignment(SwingConstants.TRAILING);
        label4j_std_1.setBounds(0, 305, 138, 16);
        jDesktopPane1.add(label4j_std_1);
       
        populatePrinterList(JPrint.getDefaultPrinterQueueName());
        String numberOfLabels = ctrl.getKeyValueWithDefault("QM SAMPLE LABELS", "4", "Number of Labels per Sample");
        spinnerCopies.setValue(Integer.valueOf(numberOfLabels));
View Full Code Here

Examples of com.commander4j.gui.JLabel4j_std

          textFieldTranslatedDescripton.setCaretPosition(0);
          textFieldTranslatedDescripton.setBounds(164, 60, 280, 21);
          jDesktopPane1.add(textFieldTranslatedDescripton);
        }
        {
          jLabel1 = new JLabel4j_std();
          jDesktopPane1.add(jLabel1);
          jLabel1.setText(lang.get("lbl_Module_ID"));
          jLabel1.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel1.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel1.setBounds(0, 10, 152, 21);
        }
        {
          lblReportType = new JLabel4j_std();
          lblReportType.setText(lang.get("lbl_Module_Report_Type"));
          lblReportType.setHorizontalAlignment(SwingConstants.TRAILING);
          lblReportType.setBounds(0, 206, 152, 21);
          jDesktopPane1.add(lblReportType);
        }
        {
          jTextFieldModuleId = new JTextField4j();
          jDesktopPane1.add(jTextFieldModuleId);
          jTextFieldModuleId.setHorizontalAlignment(SwingConstants.LEFT);
          jTextFieldModuleId.setEditable(false);
          jTextFieldModuleId.setBounds(164, 10, 280, 21);
          jTextFieldModuleId.setEnabled(false);
        }
        {
          jTextFieldResourceKey = new JTextField4j();
          AbstractDocument doc = (AbstractDocument) jTextFieldResourceKey.getDocument();
          doc.setDocumentFilter(new JFixedSizeFilter(JDBModule.field_description));
          jDesktopPane1.add(jTextFieldResourceKey);
          jTextFieldResourceKey.setFocusCycleRoot(true);
          jTextFieldResourceKey.setBounds(164, 35, 280, 21);
          jTextFieldResourceKey.addKeyListener(new KeyAdapter() {
            public void keyTyped(KeyEvent evt) {
              jButtonUpdate.setEnabled(true);
            }
          });
        }
        {

          jButtonUpdate = new JButton4j(Common.icon_update);
          jDesktopPane1.add(jButtonUpdate);
          jButtonUpdate.setEnabled(false);
          jButtonUpdate.setText(lang.get("btn_Save"));
          jButtonUpdate.setHorizontalTextPosition(SwingConstants.RIGHT);
          jButtonUpdate.setMnemonic(lang.getMnemonicChar());
          jButtonUpdate.setBounds(136, 424, 112, 32);
          jButtonUpdate.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {

              module.setResourceKey(jTextFieldResourceKey.getText());

              module.setIconFilename(jTextFieldIconFilename.getText());
              module.setHelpSetID(jTextFieldHelpsetid.getText());

              module.setType((String) jComboBoxType.getSelectedItem());
              module.setReportType((String) comboBox.getSelectedItem());

              if (jCheckBoxDesktop.isSelected())
                module.setDKActive("Y");
              else
                module.setDKActive("N");

              if (jCheckBoxScanner.isSelected())
                module.setRFActive("Y");
              else
                module.setRFActive("N");

              if (jCheckBoxPrintPreview.isSelected())
                module.setPrintPreview("Y");
              else
                module.setPrintPreview("N");

              if (jCheckBoxPrintDialog.isSelected())
                module.setPrintDialog("Y");
              else
                module.setPrintDialog("N");

              module.setPrintCopies(Integer.valueOf(jSpinnerPrintCopies.getValue().toString()));

              module.setReportFilename(jTextFieldReportFilename.getText());
              module.setExecFilename(jTextFieldExecFilename.getText());
              module.setExecDir(jTextFieldExecDir.getText());
             
              module.setAutoLabelCommandFilename(jTextFieldAutoLabelCommandFilename.getText());
              module.setAutoLabelLabelFilename(jTextFieldAutoLabelLabelFilename.getText());

              if (module.update() == false)
              {
                JUtility.errorBeep();
                JOptionPane.showMessageDialog(null, module.getErrorMessage(), lang.get("err_Error"), JOptionPane.ERROR_MESSAGE);
              }

              jButtonUpdate.setEnabled(false);
            }
          });
        }
        {

          jButtonClose = new JButton4j(Common.icon_close);
          jDesktopPane1.add(jButtonClose);
          jButtonClose.setText(lang.get("btn_Close"));
          jButtonClose.setMnemonic(lang.getMnemonicChar());
          jButtonClose.setBounds(364, 424, 112, 32);
          jButtonClose.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              dispose();
            }
          });
        }
        {
          jLabel3 = new JLabel4j_std();
          jDesktopPane1.add(jLabel3);
          jLabel3.setText(lang.get("lbl_Module_Type"));
          jLabel3.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel3.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel3.setBounds(0, 93, 152, 21);
        }
        {
          jLabel4 = new JLabel4j_std();
          jDesktopPane1.add(jLabel4);
          jLabel4.setText(lang.get("lbl_Module_Desktop"));
          jLabel4.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel4.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel4.setBounds(0, 122, 152, 21);
        }
        {
          jLabel5 = new JLabel4j_std();
          jDesktopPane1.add(jLabel5);
          jLabel5.setText(lang.get("lbl_Description"));
          jLabel5.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel5.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel5.setBounds(0, 60, 152, 21);
        }
        {
          comboBox = new JComboBox4j<String>();
          comboBox.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent arg0) {
              jButtonUpdate.setEnabled(true);
            }
          });
          comboBox.setBounds(164, 206, 180, 23);
          comboBox.addItem("");
          comboBox.addItem("Standard");
          comboBox.addItem("Label");
          jDesktopPane1.add(comboBox);
        }
        {
          jComboBoxType = new JComboBox4j<String>();
          jDesktopPane1.add(jComboBoxType);
          jComboBoxType.setEnabled(true);
          jComboBoxType.setEditable(false);
          jComboBoxType.setLightWeightPopupEnabled(true);
          jComboBoxType.setIgnoreRepaint(false);
          jComboBoxType.setBounds(164, 93, 180, 23);
          jComboBoxType.addItem("EXEC");
          jComboBoxType.addItem("FORM");
          jComboBoxType.addItem("FUNCTION");
          jComboBoxType.addItem("MENU");
          jComboBoxType.addItem("REPORT");
          jComboBoxType.addItem("USER");
          jComboBoxType.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              new_type = jComboBoxType.getSelectedItem();
              if (new_type != null)
              {
                if (new_type.equals(current_type) != true)
                {
                  // module_updated = true;
                  jButtonUpdate.setEnabled(true);
                  jButtonIconPreview.setIcon(JDBModule.getModuleIcon(jTextFieldIconFilename.getText(), (String) jComboBoxType.getSelectedItem()));
                }

                if (new_type.equals("REPORT") || new_type.equals("USER"))
                {
                  jTextFieldReportFilename.setEnabled(true);
                  jButtonReportFileChooser.setEnabled(true);
                  jCheckBoxPrintPreview.setEnabled(true);
                  jCheckBoxPrintDialog.setEnabled(true);
                  jSpinnerPrintCopies.setEnabled(true);
                  comboBox.setEnabled(true);
                  jTextFieldAutoLabelCommandFilename.setEnabled(true);
                  jTextFieldAutoLabelLabelFilename.setEnabled(true);
                  jButtonAutoLabelCommandFileChooser.setEnabled(true);
                  jButtonAutoLabelLabelDirChooser.setEnabled(true);
                }
                else
                {
                  jTextFieldReportFilename.setEnabled(false);
                  jButtonReportFileChooser.setEnabled(false);
                  jCheckBoxPrintPreview.setEnabled(false);
                  jCheckBoxPrintDialog.setEnabled(false);
                  jSpinnerPrintCopies.setEnabled(false);
                  comboBox.setEnabled(false);
                  jTextFieldAutoLabelCommandFilename.setEnabled(false);
                  jTextFieldAutoLabelLabelFilename.setEnabled(false);
                  jButtonAutoLabelCommandFileChooser.setEnabled(false);
                  jButtonAutoLabelLabelDirChooser.setEnabled(false);
                }

                if (new_type.equals("EXEC"))
                {
                  jTextFieldExecFilename.setEnabled(true);
                  jButtonExecFileChooser.setEnabled(true);
                  jTextFieldExecDir.setEnabled(true);
                  jButtonExecDirChooser.setEnabled(true);
                }
                else
                {
                  jTextFieldExecFilename.setEnabled(false);
                  jButtonExecFileChooser.setEnabled(false);
                  jTextFieldExecDir.setEnabled(false);
                  jButtonExecDirChooser.setEnabled(false);
                }
              }
            }
          });
        }
        {
          jCheckBoxScanner = new JCheckBox4j();
          jDesktopPane1.add(jCheckBoxScanner);
          jCheckBoxScanner.setSelected(true);
          jCheckBoxScanner.setBounds(164, 146, 21, 21);
          jCheckBoxScanner.setBackground(new java.awt.Color(255, 255, 255));
          jCheckBoxScanner.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              // module_updated = true;
              jButtonUpdate.setEnabled(true);
            }
          });
        }
        {
          jCheckBoxDesktop = new JCheckBox4j();
          jDesktopPane1.add(jCheckBoxDesktop);
          jCheckBoxDesktop.setSelected(true);
          jCheckBoxDesktop.setBounds(164, 122, 21, 21);
          jCheckBoxDesktop.setBackground(new java.awt.Color(255, 255, 255));
          jCheckBoxDesktop.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              // module_updated = true;
              jButtonUpdate.setEnabled(true);
            }
          });
        }
        {
          jLabel6 = new JLabel4j_std();
          jDesktopPane1.add(jLabel6);
          jLabel6.setText(lang.get("lbl_Module_Scanner"));
          jLabel6.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel6.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel6.setBounds(0, 146, 152, 21);
        }

        {
          jLabelMnemonic = new JLabel4j_std();
          jDesktopPane1.add(jLabelMnemonic);
          jLabelMnemonic.setText(lang.get("lbl_Language_Mnemonic"));
          jLabelMnemonic.setBounds(449, 60, 112, 21);
          jLabelMnemonic.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabelMnemonic.setHorizontalTextPosition(SwingConstants.RIGHT);
        }
        {
          jTextFieldMnemonic = new JTextField4j();
          jTextFieldMnemonic.setEditable(false);
          AbstractDocument doc = (AbstractDocument) jTextFieldMnemonic.getDocument();
          doc.setDocumentFilter(new JFixedSizeFilter(JDBModule.field_mneumonic));

          jDesktopPane1.add(jTextFieldMnemonic);
          jTextFieldMnemonic.setText("");

          jTextFieldMnemonic.setBounds(566, 60, 42, 21);
          jTextFieldMnemonic.setToolTipText("Character to underline");
          jTextFieldMnemonic.addKeyListener(new KeyAdapter() {
            public void keyTyped(KeyEvent evt) {
              jButtonUpdate.setEnabled(true);
            }
          });
        }
        {
          jLabel2 = new JLabel4j_std();
          jDesktopPane1.add(jLabel2);
          jLabel2.setText(lang.get("lbl_Module_Executable_Directory"));
          jLabel2.setBounds(0, 291, 152, 21);
          jLabel2.setHorizontalAlignment(SwingConstants.TRAILING);
        }
        {
          jTextFieldIconFilename = new JTextField4j();
          jDesktopPane1.add(jTextFieldIconFilename);
          jTextFieldIconFilename.setBounds(164, 177, 218, 22);
          jTextFieldIconFilename.addKeyListener(new KeyAdapter() {
            public void keyReleased(KeyEvent evt) {
              jButtonIconPreview.setIcon(JDBModule.getModuleIcon(jTextFieldIconFilename.getText(), (String) jComboBoxType.getSelectedItem()));
            }

            public void keyTyped(KeyEvent evt) {
              jButtonUpdate.setEnabled(true);
            }
          });
        }
        {
          jButtonIconFileChooser = new JButton4j();
          jDesktopPane1.add(jButtonIconFileChooser);
          jButtonIconFileChooser.setText("..");
          jButtonIconFileChooser.setBounds(383, 177, 17, 21);
          jButtonIconFileChooser.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {

              JFileChooser loadIco = new JFileChooser();

              try
              {
                File f = new File(new File("./images").getCanonicalPath());
                loadIco.setCurrentDirectory(f);
                loadIco.addChoosableFileFilter(new JFileFilterImages());
                loadIco.setAcceptAllFileFilterUsed(false);
                loadIco.setSelectedFile(new File(jTextFieldIconFilename.getText()));
              }
              catch (Exception e)
              {
              }

              if (loadIco.showOpenDialog(jButtonIconFileChooser) == JFileChooser.APPROVE_OPTION)
              {
                File selectedFile;
                selectedFile = loadIco.getSelectedFile();

                if (selectedFile != null)
                {
                  if (jTextFieldIconFilename.getText().compareTo(selectedFile.getName()) != 0)
                  {
                    jTextFieldIconFilename.setText(selectedFile.getName());
                    jButtonIconPreview.setIcon(JDBModule.getModuleIcon(jTextFieldIconFilename.getText(), (String) jComboBoxType.getSelectedItem()));
                    jButtonUpdate.setEnabled(true);
                  }
                }
              }
            }
          });
        }
        {
          jButtonIconPreview = new JButton4j();
          jDesktopPane1.add(jButtonIconPreview);
          jButtonIconPreview.setBounds(292, 177, 23, 22);
          jButtonIconPreview.setBorderPainted(false);
          jButtonIconPreview.setContentAreaFilled(false);
          jButtonIconPreview.setRolloverEnabled(false);
          jButtonIconPreview.setRequestFocusEnabled(false);
        }
        {
          jTextFieldHelpsetid = new JTextField4j();
          AbstractDocument doc = (AbstractDocument) jTextFieldHelpsetid.getDocument();
          doc.setDocumentFilter(new JFixedSizeFilter(JDBModule.field_helpset_id));
          jDesktopPane1.add(jTextFieldHelpsetid);
          jTextFieldHelpsetid.setBounds(164, 318, 427, 21);
          jTextFieldHelpsetid.addKeyListener(new KeyAdapter() {
            public void keyTyped(KeyEvent evt) {

              jButtonUpdate.setEnabled(true);
            }
          });
        }
        {
          jLabel7 = new JLabel4j_std();
          jDesktopPane1.add(jLabel7);
          jLabel7.setText(lang.get("lbl_Module_Help"));
          jLabel7.setBounds(0, 318, 152, 21);
          jLabel7.setHorizontalAlignment(SwingConstants.TRAILING);
        }
        {
          jButtonHelp = new JButton4j(Common.icon_help);
          jDesktopPane1.add(jButtonHelp);
          jButtonHelp.setText(lang.get("btn_Help"));
          jButtonHelp.setBounds(250, 424, 112, 32);
          jButtonHelp.setMnemonic(lang.getMnemonicChar());
        }
        {
          jTextFieldReportFilename = new JTextField4j();
          jDesktopPane1.add(jTextFieldReportFilename);
          jTextFieldReportFilename.setBounds(164, 233, 218, 22);
          jTextFieldReportFilename.addKeyListener(new KeyAdapter() {
            public void keyTyped(KeyEvent evt) {
              jButtonUpdate.setEnabled(true);
            }

            public void keyReleased(KeyEvent evt) {
              jButtonIconPreview.setIcon(JDBModule.getModuleIcon(jTextFieldIconFilename.getText(), (String) jComboBoxType.getSelectedItem()));
            }
          });
        }
        {
          jLabel8 = new JLabel4j_std();
          jDesktopPane1.add(jLabel8);
          jLabel8.setText(lang.get("lbl_Module_Icon_Filename"));
          jLabel8.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel8.setBounds(0, 178, 152, 21);
        }
        {
          jButtonReportFileChooser = new JButton4j();
          jDesktopPane1.add(jButtonReportFileChooser);
          jButtonReportFileChooser.setText("..");
          jButtonReportFileChooser.setBounds(383, 234, 17, 21);
          jButtonReportFileChooser.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {

              JFileChooser loadRpt = new JFileChooser();
              loadRpt.setAcceptAllFileFilterUsed(false);
              try
              {
                String path = "";
                if (((String) comboBox.getSelectedItem()).equals("Standard"))
                {
                  path = "./reports";
                }
                else
                {
                  path = "./labels";
                }
                File f = new File(new File(path).getCanonicalPath());
                loadRpt.setCurrentDirectory(f);

                if (((String) comboBox.getSelectedItem()).equals("Standard"))
                {
                  loadRpt.addChoosableFileFilter(new JFileFilterReports());
                }
                else
                {
                  loadRpt.addChoosableFileFilter(new JFileFilterLabels());
                }

                loadRpt.setSelectedFile(new File(jTextFieldReportFilename.getText()));
              }
              catch (Exception e)
              {
              }

              if (loadRpt.showOpenDialog(jButtonReportFileChooser) == JFileChooser.APPROVE_OPTION)
              {
                File selectedFile;
                selectedFile = loadRpt.getSelectedFile();

                if (selectedFile != null)
                {
                  if (jTextFieldReportFilename.getText().compareTo(selectedFile.getName()) != 0)
                  {
                    jTextFieldReportFilename.setText(selectedFile.getName());
                    jButtonUpdate.setEnabled(true);
                  }
                }
              }
            }
          });
        }
        {
          jTextFieldExecDir = new JTextField4j();
          jDesktopPane1.add(jTextFieldExecDir);
          jTextFieldExecDir.setBounds(164, 290, 427, 22);
          jTextFieldExecDir.addKeyListener(new KeyAdapter() {
            public void keyTyped(KeyEvent evt) {
              jButtonUpdate.setEnabled(true);
            }

            public void keyReleased(KeyEvent evt) {
              jButtonIconPreview.setIcon(JDBModule.getModuleIcon(jTextFieldIconFilename.getText(), (String) jComboBoxType.getSelectedItem()));
            }
          });
        }
        {
          jTextFieldExecFilename = new JTextField4j();
          jDesktopPane1.add(jTextFieldExecFilename);
          jTextFieldExecFilename.setBounds(164, 262, 427, 22);
          jTextFieldExecFilename.addKeyListener(new KeyAdapter() {
            public void keyTyped(KeyEvent evt) {
              jButtonUpdate.setEnabled(true);
            }

            public void keyReleased(KeyEvent evt) {
              jButtonIconPreview.setIcon(JDBModule.getModuleIcon(jTextFieldIconFilename.getText(), (String) jComboBoxType.getSelectedItem()));
            }
          });
        }
        {
          jLabel9 = new JLabel4j_std();
          jDesktopPane1.add(jLabel9);
          jLabel9.setText(lang.get("lbl_Module_Report_Filename"));
          jLabel9.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel9.setBounds(0, 234, 152, 21);
        }
        {
          jLabel10 = new JLabel4j_std();
          jDesktopPane1.add(jLabel10);
          jLabel10.setText(lang.get("lbl_Module_Executable_Filename"));
          jLabel10.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel10.setBounds(0, 263, 152, 21);
        }
        {
          jButtonExecDirChooser = new JButton4j();
          jDesktopPane1.add(jButtonExecDirChooser);
          jButtonExecDirChooser.setText("..");
          jButtonExecDirChooser.setBounds(591, 290, 17, 21);
          jButtonExecDirChooser.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {

              JFileChooser loadDir = new JFileChooser();

              try
              {
                File f = new File(new File("").getCanonicalPath());
                loadDir.setFileSelectionMode(JFileChooser.DIRECTORIES_ONLY);
                loadDir.setCurrentDirectory(f);
                loadDir.setSelectedFile(new File(jTextFieldExecDir.getText()));

                if (loadDir.showOpenDialog(jButtonExecDirChooser) == JFileChooser.APPROVE_OPTION)
                {
                  File selectedFile;
                  selectedFile = loadDir.getSelectedFile();

                  if (selectedFile != null)
                  {
                    if (jTextFieldExecDir.getText().compareTo(selectedFile.getCanonicalPath()) != 0)
                    {
                      jTextFieldExecDir.setText(selectedFile.getCanonicalPath());
                      jButtonUpdate.setEnabled(true);
                    }
                  }
                }

              }
              catch (Exception e)
              {
              }

            }
          });
        }
        {
          jButtonExecFileChooser = new JButton4j();
          jDesktopPane1.add(jButtonExecFileChooser);
          jButtonExecFileChooser.setText("..");
          jButtonExecFileChooser.setBounds(591, 262, 17, 21);
          jButtonExecFileChooser.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {

              JFileChooser loadExec = new JFileChooser();

              try
              {
                File f = new File(new File("").getCanonicalPath());
                loadExec.setCurrentDirectory(f);
                loadExec.addChoosableFileFilter(new JFileFilterExecs());
                loadExec.setSelectedFile(new File(jTextFieldExecFilename.getText()));

                if (loadExec.showOpenDialog(jButtonExecFileChooser) == JFileChooser.APPROVE_OPTION)
                {
                  File selectedFile;
                  selectedFile = loadExec.getSelectedFile();

                  if (selectedFile != null)
                  {
                    if (jTextFieldExecFilename.getText().compareTo(selectedFile.getName()) != 0)
                    {
                      jTextFieldExecFilename.setText(selectedFile.getCanonicalPath());
                      jButtonUpdate.setEnabled(true);
                    }
                  }
                }

              }
              catch (Exception e)
              {
              }

            }
          });
        }

        {
          jButtonExecDirChooser_1 = new JButton4j();
          jButtonExecDirChooser_1.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {

              JFileChooser loadWeb = new JFileChooser();

              try
              {
                File f = new File(new File("./help/html/commander4j").getCanonicalPath());
                loadWeb.setCurrentDirectory(f);

                loadWeb.setSelectedFile(new File(jTextFieldHelpsetid.getText()));

                if (loadWeb.showOpenDialog(jButtonExecFileChooser) == JFileChooser.APPROVE_OPTION)
                {
                  File selectedFile;
                  selectedFile = loadWeb.getSelectedFile();

                  String fullpath = selectedFile.getCanonicalPath();
                  fullpath = fullpath.replace(Common.base_dir, "{base_dir}");

                  if (selectedFile != null)
                  {
                    if (jTextFieldHelpsetid.getText().compareTo(selectedFile.getName()) != 0)
                    {
                      jTextFieldHelpsetid.setText(fullpath);
                      jButtonUpdate.setEnabled(true);
                    }
                  }
                }

              }
              catch (Exception ex)
              {
              }

            }
          });
          jButtonExecDirChooser_1.setText("..");
          jButtonExecDirChooser_1.setBounds(591, 318, 17, 21);
          jDesktopPane1.add(jButtonExecDirChooser_1);
        }

        {
          jCheckBoxPrintPreview = new JCheckBox4j();
          jCheckBoxPrintPreview.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
              jButtonUpdate.setEnabled(true);
            }
          });
          jCheckBoxPrintPreview.setSelected(true);
          jCheckBoxPrintPreview.setBackground(new Color(255, 255, 255));
          jCheckBoxPrintPreview.setBounds(566, 177, 21, 21);
          jDesktopPane1.add(jCheckBoxPrintPreview);
        }

        {
          jCheckBoxPrintDialog = new JCheckBox4j();
          jCheckBoxPrintDialog.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
              jButtonUpdate.setEnabled(true);
            }
          });
          jCheckBoxPrintDialog.setSelected(true);
          jCheckBoxPrintDialog.setBackground(new Color(255, 255, 255));
          jCheckBoxPrintDialog.setBounds(566, 205, 21, 21);
          jDesktopPane1.add(jCheckBoxPrintDialog);
        }

        {
          jLabel3_1 = new JLabel4j_std();
          jLabel3_1.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel3_1.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel3_1.setText(lang.get("lbl_Module_Print_Preview"));
          jLabel3_1.setBounds(421, 177, 141, 21);
          jDesktopPane1.add(jLabel3_1);
        }

        {
          jLabel3_2 = new JLabel4j_std();
          jLabel3_2.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel3_2.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel3_2.setText(lang.get("lbl_Module_Print_Dialog"));
          jLabel3_2.setBounds(415, 205, 147, 21);
          jDesktopPane1.add(jLabel3_2);
        }

        {
          jLabel3_3 = new JLabel4j_std();
          jLabel3_3.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel3_3.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel3_3.setText(lang.get("lbl_Module_Print_Copies"));
          jLabel3_3.setBounds(421, 233, 141, 21);
          jDesktopPane1.add(jLabel3_3);
        }

        {
          jSpinnerPrintCopies = new JSpinner();
          jSpinnerPrintCopies.addChangeListener(new ChangeListener() {
            public void stateChanged(ChangeEvent e) {
              jButtonUpdate.setEnabled(true);
            }
          });
          jSpinnerPrintCopies.setFont(Common.font_std);
          jSpinnerPrintCopies.setBounds(566, 233, 42, 21);
          jDesktopPane1.add(jSpinnerPrintCopies);
        }
       
        {
          lblResourceKey = new JLabel4j_std();
          lblResourceKey.setText(lang.get("lbl_Language_Key"));
          lblResourceKey.setHorizontalTextPosition(SwingConstants.RIGHT);
          lblResourceKey.setHorizontalAlignment(SwingConstants.RIGHT);
          lblResourceKey.setBounds(0, 35, 152, 21);
          jDesktopPane1.add(lblResourceKey);
        }
       
        JLabel4j_std label4j_std = new JLabel4j_std();
        label4j_std.setText(lang.get("lbl_Command_File"));
        label4j_std.setHorizontalAlignment(SwingConstants.TRAILING);
        label4j_std.setBounds(0, 364, 152, 21);
        jDesktopPane1.add(label4j_std);
       
        JLabel4j_std label4j_std_1 = new JLabel4j_std();
        label4j_std_1.setText(lang.get("lbl_Label_File"));
        label4j_std_1.setHorizontalAlignment(SwingConstants.TRAILING);
        label4j_std_1.setBounds(0, 391, 152, 21);
        jDesktopPane1.add(label4j_std_1);
        jTextFieldAutoLabelCommandFilename.addKeyListener(new KeyAdapter() {
          @Override
          public void keyTyped(KeyEvent e) {
            jButtonUpdate.setEnabled(true);
          }
        });
       
        jTextFieldAutoLabelCommandFilename.setBounds(164, 363, 218, 22);
        jDesktopPane1.add(jTextFieldAutoLabelCommandFilename);
        jTextFieldAutoLabelLabelFilename.addKeyListener(new KeyAdapter() {
          @Override
          public void keyTyped(KeyEvent e) {
            jButtonUpdate.setEnabled(true);
          }
        });
       
        jTextFieldAutoLabelLabelFilename.setBounds(164, 391, 218, 21);
        jDesktopPane1.add(jTextFieldAutoLabelLabelFilename);
       
       
        jButtonAutoLabelCommandFileChooser.addActionListener(new ActionListener() {
          public void actionPerformed(ActionEvent e) {
            JFileChooser loadCMD = new JFileChooser();

            try
            {
              String path = jTextFieldAutoLabelCommandFilename.getText();
              if (path.equals(""))
              {
                path=Common.auto_label_command;
              }
              File f = new File(new File(path).getCanonicalPath());
              loadCMD.setCurrentDirectory(f);
              loadCMD.setAcceptAllFileFilterUsed(false);
              loadCMD.addChoosableFileFilter(new JFileFilterTXT());
              loadCMD.setSelectedFile(new File(jTextFieldReportFilename.getText()));
            }
            catch (Exception e3)
            {
            }

            if (loadCMD.showOpenDialog(jButtonAutoLabelCommandFileChooser) == JFileChooser.APPROVE_OPTION)
            {
              File selectedFile;
              selectedFile = loadCMD.getSelectedFile();

              if (selectedFile != null)
              {
                if (jTextFieldAutoLabelCommandFilename.getText().compareTo(selectedFile.getName()) != 0)
                {
                  jTextFieldAutoLabelCommandFilename.setText(selectedFile.getName());
                  jButtonUpdate.setEnabled(true);
                }
              }
            }
          }
        });
        jButtonAutoLabelCommandFileChooser.setText("..");
        jButtonAutoLabelCommandFileChooser.setBounds(383, 364, 17, 21);
        jDesktopPane1.add(jButtonAutoLabelCommandFileChooser);
       

        jButtonAutoLabelLabelDirChooser.addActionListener(new ActionListener() {
          public void actionPerformed(ActionEvent e) {
         
            JFileChooser loadLab = new JFileChooser();

            try
            {
              String path = Common.auto_label_labels;
              File f = new File(new File(path).getCanonicalPath());
              loadLab.setCurrentDirectory(f);
              loadLab.setAcceptAllFileFilterUsed(false);
              loadLab.addChoosableFileFilter(new JFileFilterLabels());
              loadLab.setSelectedFile(new File(jTextFieldAutoLabelLabelFilename.getText()));
             
              if (loadLab.showOpenDialog(jButtonReportFileChooser) == JFileChooser.APPROVE_OPTION)
              {
                File selectedFile;
                selectedFile = loadLab.getSelectedFile();

                if (selectedFile != null)
                {
                  if (jTextFieldAutoLabelLabelFilename.getText().compareTo(selectedFile.getName()) != 0)
                  {
                    jTextFieldAutoLabelLabelFilename.setText(selectedFile.getName());
                    jButtonUpdate.setEnabled(true);
                  }
                }
              }
            }
            catch (Exception e2)
            {
            }


          }
        });
        jButtonAutoLabelLabelDirChooser.setText("..");
        jButtonAutoLabelLabelDirChooser.setBounds(383, 391, 17, 21);
        jDesktopPane1.add(jButtonAutoLabelLabelDirChooser);
         
        JLabel4j_std label4j_std_AutoLabeller = new JLabel4j_std();
        label4j_std_AutoLabeller.setText(lang.get("lbl_Auto_Labeller"));
        label4j_std_AutoLabeller.setHorizontalAlignment(SwingConstants.CENTER);
        label4j_std_AutoLabeller.setBounds(163, 341, 237, 21);
        jDesktopPane1.add(label4j_std_AutoLabeller);
       
      }
      postInitGUI();
    }
View Full Code Here

Examples of com.commander4j.gui.JLabel4j_std

      {
        jDesktopPane1 = new JDesktopPane();
        jDesktopPane1.setBackground(Color.WHITE);
        getContentPane().add(jDesktopPane1, BorderLayout.CENTER);
        {
          jLabel1 = new JLabel4j_std();
          jDesktopPane1.add(jLabel1, new GridBagConstraints(0, 0, 1, 1, 0.0, 0.0, GridBagConstraints.CENTER, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
          jLabel1.setText(lang.get("lbl_Customer_ID"));
          jLabel1.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel1.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel1.setBounds(22, 22, 175, 21);
        }
        {
          jTextFieldID = new JTextField4j();
          jDesktopPane1.add(jTextFieldID, new GridBagConstraints(2, 0, 1, 1, 0.0, 0.0, GridBagConstraints.CENTER, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
          jTextFieldID.setHorizontalAlignment(SwingConstants.LEFT);
          jTextFieldID.setEditable(false);
          jTextFieldID.setEnabled(false);
          jTextFieldID.setBounds(204, 22, 141, 21);
        }
        {
          jLabel3 = new JLabel4j_std();
          jDesktopPane1.add(jLabel3, new GridBagConstraints(0, 1, 1, 1, 0.0, 0.0, GridBagConstraints.CENTER, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
          jLabel3.setText(lang.get("lbl_Customer_Name"));
          jLabel3.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel3.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel3.setBounds(22, 55, 175, 21);
        }

        {
          jTextFieldName = new JTextField4j();
          jDesktopPane1.add(jTextFieldName, new GridBagConstraints(2, 1, 1, 1, 0.0, 0.0, GridBagConstraints.CENTER, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
          jTextFieldName.setBounds(204, 55, 244, 21);
          jTextFieldName.addKeyListener(new KeyAdapter() {
            public void keyTyped(KeyEvent evt) {
              jButtonUpdate.setEnabled(true);
            }
          });
          jTextFieldName.setFocusCycleRoot(true);
        }
        {
          jButtonUpdate = new JButton4j(Common.icon_update);
          jDesktopPane1.add(jButtonUpdate, new GridBagConstraints(0, 2, 1, 1, 0.0, 0.0, GridBagConstraints.CENTER, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
          jButtonUpdate.setEnabled(false);
          jButtonUpdate.setText(lang.get("btn_Save"));
          jButtonUpdate.setMnemonic(lang.getMnemonicChar());
          jButtonUpdate.setHorizontalTextPosition(SwingConstants.RIGHT);
          jButtonUpdate.setBounds(72, 197, 112, 28);
          jButtonUpdate.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              mt.setName(jTextFieldName.getText());
              if (checkBoxPrintOnLabel.isSelected()) {
                mt.setPrintOnLabel("Y");
              }
              else {
                mt.setPrintOnLabel("N");
              }
             
              if (checkBoxOverridePackLabel.isSelected())
              {
                if (comboBoxPackModuleID.getSelectedItem().toString().equals(""))
                {
                  mt.setOverridePackLabel("N");
                  mt.setPackLabelModuleID("");
                }
                else
                {
                  mt.setOverridePackLabel("Y");
                  mt.setPackLabelModuleID(comboBoxPackModuleID.getSelectedItem().toString());
                }
               
              }
              else
              {
                mt.setOverridePackLabel("N");
                mt.setPackLabelModuleID("");
              }
             
              if (checkBoxOverridePalletLabel.isSelected())
              {
                if (comboBoxPalletModuleID.getSelectedItem().toString().equals(""))
                {
                  mt.setOverridePalletLabel("N");
                  mt.setPalletLabelModuleID("");
                }
                else
                {
                  mt.setOverridePalletLabel("Y");
                  mt.setPalletLabelModuleID(comboBoxPalletModuleID.getSelectedItem().toString());
                }
              }
              else
              {
                mt.setOverridePalletLabel("N");
                mt.setPalletLabelModuleID("");
             
             
              mt.update();
              jButtonUpdate.setEnabled(false);
            }
          });
        }
        {
          jButtonHelp = new JButton4j(Common.icon_help);
          jDesktopPane1.add(jButtonHelp);
          jButtonHelp.setText(lang.get("btn_Help"));
          jButtonHelp.setMnemonic(lang.getMnemonicChar());
          jButtonHelp.setBounds(205, 197, 112, 28);
        }
        {
          label = new JLabel4j_std();
          label.setText((String) null);
          label.setHorizontalTextPosition(SwingConstants.RIGHT);
          label.setHorizontalAlignment(SwingConstants.RIGHT);
          label.setBounds(22, 88, 175, 21);
          label.setText(lang.get("lbl_Print_Customer_on_Label"));
          jDesktopPane1.add(label);
        }
        {
          checkBoxPrintOnLabel = new JCheckBox4j();
          checkBoxPrintOnLabel.setSelected(true);
          checkBoxPrintOnLabel.setBackground(Color.WHITE);
          checkBoxPrintOnLabel.setBounds(201, 88, 21, 24);
          checkBoxPrintOnLabel.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
              jButtonUpdate.setEnabled(true);
            }
          });
          jDesktopPane1.add(checkBoxPrintOnLabel);

        }
        {
          jButtonClose = new JButton4j(Common.icon_close);
          jDesktopPane1.add(jButtonClose, new GridBagConstraints(2, 2, 1, 1, 0.0, 0.0, GridBagConstraints.CENTER, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
          jButtonClose.setText(lang.get("btn_Close"));
          jButtonClose.setMnemonic(lang.getMnemonicChar());
          jButtonClose.setBounds(336, 197, 112, 28);
          jButtonClose.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              dispose();
            }
          });
        }
        checkBoxOverridePackLabel.addActionListener(new ActionListener() {
          public void actionPerformed(ActionEvent arg0) {
            setButtonStates();
          }
        });
       

        checkBoxOverridePackLabel.setBackground(Color.WHITE);
        checkBoxOverridePackLabel.setBounds(201, 124, 21, 24);
        jDesktopPane1.add(checkBoxOverridePackLabel);
        checkBoxOverridePalletLabel.addActionListener(new ActionListener() {
          public void actionPerformed(ActionEvent e) {
            setButtonStates();
          }
        });
       

        checkBoxOverridePalletLabel.setBackground(Color.WHITE);
        checkBoxOverridePalletLabel.setBounds(201, 160, 21, 24);
        jDesktopPane1.add(checkBoxOverridePalletLabel);
       
        JLabel4j_std label4j_std = new JLabel4j_std();
        label4j_std.setText(lang.get("lbl_Override_Pack_Label"));
        label4j_std.setHorizontalTextPosition(SwingConstants.RIGHT);
        label4j_std.setHorizontalAlignment(SwingConstants.RIGHT);
        label4j_std.setBounds(22, 124, 175, 21);
        jDesktopPane1.add(label4j_std);
       
        JLabel4j_std label4j_std_1 = new JLabel4j_std();
        label4j_std_1.setText(lang.get("lbl_Override_Pallet_Label"));
        label4j_std_1.setHorizontalTextPosition(SwingConstants.RIGHT);
        label4j_std_1.setHorizontalAlignment(SwingConstants.RIGHT);
        label4j_std_1.setBounds(22, 160, 175, 21);
        jDesktopPane1.add(label4j_std_1);
       
        ComboBoxModel jComboBox1Model = new DefaultComboBoxModel(moduleList);
        comboBoxPackModuleID.setModel(jComboBox1Model);
        comboBoxPackModuleID.setEnabled(false);
View Full Code Here

Examples of com.commander4j.gui.JLabel4j_std

    textFieldSSCC = new JTextField4j();
    textFieldSSCC.setBounds(672, 50, 143, 21);
    desktopPane.add(textFieldSSCC);

    final JLabel4j_std palletStatusLabel = new JLabel4j_std();
    palletStatusLabel.setText(lang.get("lbl_Pallet_Status"));
    palletStatusLabel.setBounds(672, 115, 128, 20);
    desktopPane.add(palletStatusLabel);

    final JLabel4j_std ssccLabel = new JLabel4j_std();
    ssccLabel.setText(lang.get("lbl_Pallet_SSCC"));
    ssccLabel.setBounds(672, 35, 128, 16);
    desktopPane.add(ssccLabel);

    textFieldMaterial = new JTextField4j();
    textFieldMaterial.setBounds(672, 90, 124, 21);
    desktopPane.add(textFieldMaterial);

    final JLabel4j_std materialLabel = new JLabel4j_std();
    materialLabel.setText(lang.get("lbl_Material"));
    materialLabel.setBounds(672, 75, 128, 16);
    desktopPane.add(materialLabel);

    textFieldBatch = new JTextField4j();
    textFieldBatch.setBounds(672, 175, 124, 21);
    desktopPane.add(textFieldBatch);

    final JLabel4j_std batchLabel = new JLabel4j_std();
    batchLabel.setText(lang.get("lbl_Batch"));
    batchLabel.setBounds(672, 160, 128, 16);
    desktopPane.add(batchLabel);
    buttonAssign.setEnabled(false);

    buttonAssign.setBounds(470, 150, 25, 25);
    buttonAssign.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent e)
      {
        if (textFieldDespatchLocationTo.getText().equals(""))
        {
          jStatusText.setText("Please define Destination Location");
        }
        else
        {
          jStatusText.setText("");
          if (list_unassigned.getSelectedIndex() > -1)
          {
            String item = "";
            JDBDespatch d = (JDBDespatch) list_despatch.getSelectedValue();

            for (int j = list_unassigned.getMaxSelectionIndex(); j >= list_unassigned.getMinSelectionIndex(); j--)
            {
              if (list_unassigned.isSelectedIndex(j))
              {
                item = (String) list_unassigned.getModel().getElementAt(j);

                if (d.assignSSCC(item))
                {
                  addtoList(assignedList, item);
                  removefromList(unassignedList, item);
                  jStatusText.setText("");
                }
                else
                {
                  jStatusText.setText(d.getErrorMessage());
                }
              }
            }

            list_assigned.setModel(addListtoModel(assignedList));
            list_unassigned.setModel(addListtoModel(unassignedList));
            textFieldNoOfPallets.setText(String.valueOf(assignedList.size()));

            d.setTotalPallets(assignedList.size());
            updateDespatch(d);
          }
        }
      }
    });
    desktopPane.add(buttonAssign);
    buttonUnAssign.setEnabled(false);

    buttonUnAssign.setBounds(470, 185, 25, 25);
    buttonUnAssign.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent e)
      {
        if (list_assigned.getSelectedIndex() > -1)
        {
          String item = "";
          JDBDespatch d = (JDBDespatch) list_despatch.getSelectedValue();

          for (int j = list_assigned.getMaxSelectionIndex(); j >= list_assigned.getMinSelectionIndex(); j--)
          {
            if (list_assigned.isSelectedIndex(j))
            {
              item = (String) list_assigned.getModel().getElementAt(j);

              if (d.unassignSSCC(item))
              {
                removefromList(assignedList, item);
                addtoList(unassignedList, item);
              }
            }
          }

          list_assigned.setModel(addListtoModel(assignedList));
          list_unassigned.setModel(addListtoModel(unassignedList));
          textFieldNoOfPallets.setText(String.valueOf(assignedList.size()));

          d.setTotalPallets(assignedList.size());
          updateDespatch(d);
        }
      }
    });
    desktopPane.add(buttonUnAssign);

    newButton.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent e)
      {
        int question = JOptionPane.showConfirmDialog(Common.mainForm, lang.get("dlg_Despatch_Create"), lang.get("dlg_Confirm"), JOptionPane.YES_NO_OPTION, 0, Common.icon_confirm);

        if (question == 0)
        {
          JDBDespatch d = new JDBDespatch(Common.selectedHostID, Common.sessionID);
          String number = "";
          number = d.generateNewDespatchNo();

          if (number.equals("") == false)
          {

            if (d.create())
            {
              d.updateUserID(number, Common.userList.getUser(Common.sessionID).getUserId());
              populateDespatchList(number);
              setConfirmButtonStatus();
            }
            else
            {
              JUtility.errorBeep();
              JOptionPane.showMessageDialog(Common.mainForm, d.getErrorMessage(), lang.get("dlg_Error"), JOptionPane.ERROR_MESSAGE,Common.icon_confirm);
            }
          }
          else
          {
            JUtility.errorBeep();
            JOptionPane.showMessageDialog(Common.mainForm, d.getErrorMessage(), lang.get("dlg_Error"), JOptionPane.ERROR_MESSAGE);
          }
        }
      }
    });
    newButton.setText(lang.get("btn_New"));
    newButton.setBounds(2, 388, 116, 30);
    desktopPane.add(newButton);

    deleteButton.setText(lang.get("btn_Delete"));
    deleteButton.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent e)
      {
        if (list_despatch.getModel().getSize() > 0)
        {
          if (list_despatch.getSelectedIndex() >= 0)
          {
            JDBDespatch d = (JDBDespatch) list_despatch.getSelectedValue();

            int question = JOptionPane.showConfirmDialog(Common.mainForm, lang.get("dlg_Despatch_Delete") + " " + d.getDespatchNo() + " ?", lang.get("dlg_Confirm"), JOptionPane.YES_NO_OPTION, 0, Common.icon_confirm);

            if (question == 0)
            {
              d.delete();
              populateDespatchList("");
              setConfirmButtonStatus();
            }
          }
        }
      }
    });
    deleteButton.setBounds(238, 388, 116, 30);
    desktopPane.add(deleteButton);

    findButton.setText(lang.get("btn_Find"));
    findButton.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent e)
      {
        buildUnassignedSQL();
        populateUnassignedList(listStatement, "");
      }
    });
    findButton.setBounds(672, 298, 143, 30);
    desktopPane.add(findButton);

    final JButton4j printButton = new JButton4j(Common.icon_report);
    printButton.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent e)
      {
        if (list_despatch.getModel().getSize() > 0)
        {
          if (list_despatch.getSelectedIndex() >= 0)
          {
            JDBDespatch d = (JDBDespatch) list_despatch.getSelectedValue();
            HashMap<String, Object> parameters = new HashMap<String, Object>();
            parameters.put("p_despatch_no", d.getDespatchNo());
            JLaunchReport.runReport("RPT_DESPATCH", parameters, "", null, "");
          }
        }
      }
    });
    printButton.setText(lang.get("btn_Print"));
    printButton.setBounds(474, 388, 116, 30);
    desktopPane.add(printButton);

    jLabel10 = new JLabel4j_std();
    jLabel10.setComponentOrientation(ComponentOrientation.RIGHT_TO_LEFT);
    jLabel10.setHorizontalAlignment(SwingConstants.TRAILING);
    jLabel10.setText(lang.get("lbl_Limit"));
    jLabel10.setBounds(672, 244, 128, 21);
    desktopPane.add(jLabel10);

    jCheckBoxLimit = new JCheckBox4j();
    jCheckBoxLimit.setSelected(true);
    jCheckBoxLimit.setBackground(new Color(255, 255, 255));
    jCheckBoxLimit.setBounds(672, 264, 21, 21);
    desktopPane.add(jCheckBoxLimit);

    spinnerUnassignedLimit = new JSpinner();
    JSpinner.NumberEditor ne1 = new JSpinner.NumberEditor(spinnerUnassignedLimit);
    ne1.getTextField().setFont(Common.font_std);
    spinnerUnassignedLimit.setEditor(ne1);
    spinnerUnassignedLimit.setBounds(701, 264, 114, 20);
    spinnerUnassignedLimit.setValue(1000);
    desktopPane.add(spinnerUnassignedLimit);

    final JButton4j closeButton = new JButton4j(Common.icon_close);

    closeButton.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent e)
      {
        dispose();
      }
    });
    closeButton.setText(lang.get("btn_Close"));
    closeButton.setMnemonic(lang.getMnemonicChar());
    closeButton.setBounds(710, 388, 116, 30);
    desktopPane.add(closeButton);

    jButtonHelp.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent e)
      {
      }
    });
    jButtonHelp.setText(lang.get("btn_Help"));
    jButtonHelp.setBounds(592, 388, 116, 30);
    desktopPane.add(jButtonHelp);

    //
    final JHelp help = new JHelp();
    help.enableHelpOnButton(jButtonHelp, JUtility.getHelpSetIDforModule("FRM_ADMIN_DESPATCH"));

    confirmButton.setText(lang.get("btn_Confirm"));
    confirmButton.setEnabled(false);
    confirmButton.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent e)
      {
        if (list_despatch.getModel().getSize() > 0)
        {
          if (list_despatch.getSelectedIndex() >= 0)
          {
            JDBDespatch d = (JDBDespatch) list_despatch.getSelectedValue();

            int n = JOptionPane.showConfirmDialog(Common.mainForm, lang.get("dlg_Despatch_Confirm") + " " + d.getDespatchNo() + " ?", lang.get("dlg_Confirm"), JOptionPane.YES_NO_OPTION, 0, Common.icon_confirm);

            if (n == 0)
            {
              d.getDespatchProperties();
              if (d.confirm())
              {
                populateDespatchList("");
                setConfirmButtonStatus();
              }
              else
              {
                JUtility.errorBeep();
                JOptionPane.showMessageDialog(Common.mainForm, d.getErrorMessage(), lang.get("dlg_Error"), JOptionPane.ERROR_MESSAGE,Common.icon_confirm);
                populateDespatchList("");
              }
            }
          }
        }
      }
    });

    confirmButton.setBounds(356, 388, 116, 30);
    desktopPane.add(confirmButton);

    final JLabel4j_title despatchesLabel = new JLabel4j_title();
    despatchesLabel.setText(lang.get("lbl_Despatches"));
    despatchesLabel.setBounds(10, 10, 75, 16);
    desktopPane.add(despatchesLabel);

    final JLabel4j_title unassignedLabel = new JLabel4j_title();
    unassignedLabel.setText(lang.get("lbl_Unassigned"));
    unassignedLabel.setBounds(510, 10, 150, 16);
    desktopPane.add(unassignedLabel);

    final JLabel4j_title assignedLabel = new JLabel4j_title();
    assignedLabel.setText(lang.get("lbl_Assigned"));
    assignedLabel.setBounds(310, 10, 150, 16);
    desktopPane.add(assignedLabel);

    final JLabel4j_title palletFilterCriteriaLabel = new JLabel4j_title();
    palletFilterCriteriaLabel.setText(lang.get("lbl_Unassigned_Filter"));
    palletFilterCriteriaLabel.setBounds(672, 15, 125, 16);
    desktopPane.add(palletFilterCriteriaLabel);

    final JButton4j refreshButton = new JButton4j(Common.icon_refresh);
    refreshButton.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent e)
      {
        refresh();
      }
    });
    refreshButton.setText(lang.get("btn_Refresh"));
    refreshButton.setBounds(120, 388, 116, 30);
    desktopPane.add(refreshButton);

    SpinnerNumberModel jSpinnerIntModel = new SpinnerNumberModel();
    jSpinnerIntModel.setMinimum(1);
    jSpinnerIntModel.setMaximum(50000);
    jSpinnerIntModel.setStepSize(1);
    JSpinner.NumberEditor ne2 = new JSpinner.NumberEditor(spinnerDespatchLimit);
    ne2.getTextField().setFont(Common.font_std);
    spinnerDespatchLimit.setEditor(ne2);
    spinnerDespatchLimit.setModel(jSpinnerIntModel);
    spinnerDespatchLimit.setBounds(100, 303, 60, 20);
    spinnerDespatchLimit.setValue(50);
    desktopPane.add(spinnerDespatchLimit);

    jLabel10_1 = new JLabel4j_std();
    jLabel10_1.setHorizontalAlignment(SwingConstants.TRAILING);
    jLabel10_1.setText(lang.get("lbl_Limit"));
    jLabel10_1.setBounds(15, 302, 70, 21);
    desktopPane.add(jLabel10_1);

    textFieldDespatchLocationFrom = new JTextField4j();
    textFieldDespatchLocationFrom.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent e)
      {
        if (JUtility.isNullORBlank(textFieldDespatchLocationFrom.getText()) == true)
        {
          findButton.setEnabled(false);
        }
        else
        {
          findButton.setEnabled(true);
        }
      }
    });
    textFieldDespatchLocationFrom.setEditable(false);
    textFieldDespatchLocationFrom.setBounds(172, 51, 105, 20);
    desktopPane.add(textFieldDespatchLocationFrom);

    final JLabel4j_std locationLabel_1 = new JLabel4j_std();
    locationLabel_1.setText(lang.get("lbl_From_Location"));
    locationLabel_1.setBounds(172, 32, 100, 16);
    desktopPane.add(locationLabel_1);

    final JLabel4j_std palletStatusLabel_1 = new JLabel4j_std();
    palletStatusLabel_1.setText(lang.get("lbl_Despatch_Status"));
    palletStatusLabel_1.setBounds(170, 240, 105, 20);
    desktopPane.add(palletStatusLabel_1);

    textFieldDespatchStatus = new JTextField4j();
    textFieldDespatchStatus.setEditable(false);
    textFieldDespatchStatus.setBounds(170, 261, 128, 20);
    desktopPane.add(textFieldDespatchStatus);

    textFieldDespatchLocationTo = new JTextField4j();
    textFieldDespatchLocationTo.setEditable(false);
    textFieldDespatchLocationTo.setBounds(172, 91, 105, 20);
    desktopPane.add(textFieldDespatchLocationTo);

    final JLabel4j_std locationLabel_1_1 = new JLabel4j_std();
    locationLabel_1_1.setText(lang.get("lbl_To_Location"));
    locationLabel_1_1.setBounds(172, 75, 100, 16);
    desktopPane.add(locationLabel_1_1);

    final JLabel4j_std palletStatusLabel_1_1 = new JLabel4j_std();
    palletStatusLabel_1_1.setText(lang.get("lbl_Despatch_Date"));
    palletStatusLabel_1_1.setBounds(172, 285, 90, 20);
    desktopPane.add(palletStatusLabel_1_1);

    final JLabel4j_std palletStatusLabel_1_1_1 = new JLabel4j_std();
    palletStatusLabel_1_1_1.setText(lang.get("lbl_No_Of_Pallets"));
    palletStatusLabel_1_1_1.setBounds(172, 332, 120, 20);
    desktopPane.add(palletStatusLabel_1_1_1);

    textFieldNoOfPallets = new JTextField4j();
    textFieldNoOfPallets.setEditable(false);
    textFieldNoOfPallets.setBounds(172, 352, 60, 20);
    desktopPane.add(textFieldNoOfPallets);

    jTextFieldDespatchDate = new JTextField4j();
    jTextFieldDespatchDate.setEditable(false);
    jTextFieldDespatchDate.setBounds(172, 303, 125, 20);
    desktopPane.add(jTextFieldDespatchDate);

    jButtonLookupLocationFrom = new JButton4j(Common.icon_lookup);
    jButtonLookupLocationFrom.setEnabled(false);
    jButtonLookupLocationFrom.setBounds(277, 50, 21, 21);
    jButtonLookupLocationFrom.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent evt)
      {
        JLaunchLookup.dlgAutoExec = true;
        JLaunchLookup.dlgCriteriaDefault = "Y";

        if (JLaunchLookup.locations())
        {
          textFieldDespatchLocationFrom.setText(JLaunchLookup.dlgResult);

          JDBDespatch d = (JDBDespatch) list_despatch.getSelectedValue();
          d.setLocationIDFrom(JLaunchLookup.dlgResult);
          updateDespatch(d);
        }
      }
    });
    desktopPane.add(jButtonLookupLocationFrom);

    jButtonLookupLocationTo = new JButton4j(Common.icon_lookup);
    jButtonLookupLocationTo.setEnabled(false);
    jButtonLookupLocationTo.setBounds(277, 90, 21, 21);
    jButtonLookupLocationTo.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent evt)
      {
        JLaunchLookup.dlgAutoExec = true;
        JLaunchLookup.dlgCriteriaDefault = "Y";

        if (JLaunchLookup.locations())
        {
          textFieldDespatchLocationTo.setText(JLaunchLookup.dlgResult);

          JDBDespatch d = (JDBDespatch) list_despatch.getSelectedValue();
          d.setLocationIDTo(JLaunchLookup.dlgResult);
          updateDespatch(d);
        }
      }
    });
    desktopPane.add(jButtonLookupLocationTo);

    jButtonLookupMaterial = new JButton4j(Common.icon_lookup);
    jButtonLookupMaterial.setBounds(795, 90, 21, 21);
    jButtonLookupMaterial.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent evt)
      {
        JLaunchLookup.dlgAutoExec = false;
        JLaunchLookup.dlgCriteriaDefault = "";

        if (JLaunchLookup.materials())
        {
          textFieldMaterial.setText(JLaunchLookup.dlgResult);
        }
      }
    });
    desktopPane.add(jButtonLookupMaterial);

    jButtonLookupBatch = new JButton4j(Common.icon_lookup);
    jButtonLookupBatch.setBounds(795, 175, 21, 21);
    jButtonLookupBatch.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent evt)
      {
        JLaunchLookup.dlgCriteriaDefault = textFieldMaterial.getText();
        JLaunchLookup.dlgAutoExec = true;

        if (JLaunchLookup.materialBatches())
        {
          textFieldBatch.setText(JLaunchLookup.dlgResult);
        }
      }
    });
    desktopPane.add(jButtonLookupBatch);

    confirmedRadioButton.setBackground(Color.WHITE);
    confirmedRadioButton.setText(lang.get("lbl_Confirmed"));
    confirmedRadioButton.setBounds(10, 327, 129, 24);
    confirmedRadioButton.setFont(Common.font_std);
    confirmedRadioButton.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent e)
      {
        com.commander4j.util.JWait.milliSec(100);
        populateDespatchList("");
        refresh();
      }
    });

    desktopPane.add(confirmedRadioButton);

    unconfirmedRadioButton.setBackground(Color.WHITE);
    unconfirmedRadioButton.setText(lang.get("lbl_Unconfirmed"));
    unconfirmedRadioButton.setBounds(10, 352, 129, 24);
    unconfirmedRadioButton.setSelected(true);
    unconfirmedRadioButton.setFont(Common.font_std);
    unconfirmedRadioButton.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent e)
      {
        com.commander4j.util.JWait.milliSec(100);
        populateDespatchList("");
        refresh();
        newButton.setEnabled(true);
      }
    });
    desktopPane.add(unconfirmedRadioButton);

    buttonGroup_1.add(unconfirmedRadioButton);
    buttonGroup_1.add(confirmedRadioButton);

    final JLabel4j_std palletStatusLabel_1_2 = new JLabel4j_std();
    palletStatusLabel_1_2.setText(lang.get("lbl_Trailer"));
    palletStatusLabel_1_2.setBounds(172, 115, 105, 20);
    desktopPane.add(palletStatusLabel_1_2);

    textFieldTrailer = new JTextField4j();
    textFieldTrailer.setEditable(false);
    textFieldTrailer.setBounds(172, 136, 105, 20);

    desktopPane.add(textFieldTrailer);

    final JLabel4j_std palletStatusLabel_1_2_1 = new JLabel4j_std();
    palletStatusLabel_1_2_1.setText(lang.get("lbl_Haulier"));
    palletStatusLabel_1_2_1.setBounds(172, 158, 105, 20);
    desktopPane.add(palletStatusLabel_1_2_1);

    textFieldHaulier = new JTextField4j();
    textFieldHaulier.setEditable(false);
    textFieldHaulier.setBounds(172, 176, 105, 20);
    desktopPane.add(textFieldHaulier);

    jButtonLookupTrailer = new JButton4j();
    jButtonLookupTrailer.setEnabled(false);
    jButtonLookupTrailer.setText("...");
    jButtonLookupTrailer.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent e)
      {
        String trailer;
        trailer = JOptionPane.showInputDialog(Common.mainForm, "Enter Trailer Reference");

        if (trailer != null)
        {
          JDBDespatch d = (JDBDespatch) list_despatch.getSelectedValue();
          d.setTrailer(trailer.toUpperCase());
          textFieldTrailer.setText(trailer.toUpperCase());
          updateDespatch(d);
        }
      }
    });
    jButtonLookupTrailer.setBounds(277, 135, 21, 21);
    desktopPane.add(jButtonLookupTrailer);

    jButtonLookupHaulier = new JButton4j();
    jButtonLookupHaulier.setEnabled(false);
    jButtonLookupHaulier.setText("...");
    jButtonLookupHaulier.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent e)
      {
        String haulier;
        haulier = JOptionPane.showInputDialog(Common.mainForm, "Enter Haulier Reference");

        if (haulier != null)
        {
          JDBDespatch d = (JDBDespatch) list_despatch.getSelectedValue();
          d.setHaulier(haulier.toUpperCase());
          textFieldHaulier.setText(haulier.toUpperCase());
          updateDespatch(d);
        }
      }
    });
    jButtonLookupHaulier.setBounds(277, 175, 21, 21);
    desktopPane.add(jButtonLookupHaulier);

    jStatusText = new JLabel4j_std("");
    jStatusText.setBounds(0, 428, 830, 21);
    jStatusText.setForeground(new java.awt.Color(255, 0, 0));
    jStatusText.setBorder(BorderFactory.createBevelBorder(BevelBorder.LOWERED));
    desktopPane.add(jStatusText);

    JLabel4j_std lblLoadNo = new JLabel4j_std();
    lblLoadNo.setText(lang.get("lbl_Load_No"));
    lblLoadNo.setBounds(172, 196, 105, 20);
    desktopPane.add(lblLoadNo);

    textFieldLoadNo = new JTextField4j();
    textFieldLoadNo.setText("");
    textFieldLoadNo.setEditable(false);
    textFieldLoadNo.setBounds(172, 216, 105, 20);
    desktopPane.add(textFieldLoadNo);

    jButtonLookupLoadNo = new JButton4j();
    jButtonLookupLoadNo.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent arg0)
      {
        String load;
        load = JOptionPane.showInputDialog(Common.mainForm, "Enter Load Number");

        if (load != null)
        {
          JDBDespatch d = (JDBDespatch) list_despatch.getSelectedValue();
          d.setLoadNo(load.toUpperCase());
          textFieldLoadNo.setText(load.toUpperCase());
          updateDespatch(d);

        }

      }
    });
    jButtonLookupLoadNo.setText("...");
    jButtonLookupLoadNo.setEnabled(false);
    jButtonLookupLoadNo.setBounds(277, 215, 21, 21);
    desktopPane.add(jButtonLookupLoadNo);

    JLabel4j_std label = new JLabel4j_std();
    label.setText(lang.get("lbl_User_ID"));
    label.setBounds(672, 338, 128, 16);
    desktopPane.add(label);

    textFieldUserID = new JTextField4j();
    textFieldUserID.setText("");
    textFieldUserID.setEditable(false);
    textFieldUserID.setBounds(672, 356, 122, 20);
    desktopPane.add(textFieldUserID);

    buttonSetUserID = new JButton4j((Icon) null);
    buttonSetUserID.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent e)
      {
        JLaunchLookup.dlgAutoExec = true;
        JLaunchLookup.dlgCriteriaDefault = "";

        if (JLaunchLookup.users())
        {
          textFieldUserID.setText(JLaunchLookup.dlgResult);

          JDBDespatch d = (JDBDespatch) list_despatch.getSelectedValue();
          d.updateUserID(d.getDespatchNo(), JLaunchLookup.dlgResult);

        }
      }
    });
    buttonSetUserID.setEnabled(false);
    buttonSetUserID.setBounds(795, 355, 21, 21);
    desktopPane.add(buttonSetUserID);

    textFieldDespatchNo = new JTextField4j();
    textFieldDespatchNo.setBounds(672, 215, 143, 21);
    desktopPane.add(textFieldDespatchNo);

    JLabel4j_std despatchNolabel = new JLabel4j_std();
    despatchNolabel.setText(lang.get("lbl_Despatch_No"));
    despatchNolabel.setBounds(672, 200, 143, 16);
    desktopPane.add(despatchNolabel);

    Dimension screen = Toolkit.getDefaultToolkit().getScreenSize();
    Rectangle window = getBounds();
    setLocation((screen.width - window.width) / 2, (screen.height - window.height) / 2);
View Full Code Here

Examples of com.commander4j.gui.JLabel4j_std

              dispose();
            }
          });
        }
        {
          jLabel1 = new JLabel4j_std();
          jDesktopPane1.add(jLabel1);
          jLabel1.setText(lang.get("lbl_Material"));
          jLabel1.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel1.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel1.setBounds(11, 9, 147, 21);
        }
        {
          jLabel2 = new JLabel4j_std();
          jDesktopPane1.add(jLabel2);
          jLabel2.setText(lang.get("lbl_Material_UOM_EAN"));
          jLabel2.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel2.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel2.setBounds(11, 59, 147, 21);
        }
        {
          jLabel3 = new JLabel4j_std();
          jDesktopPane1.add(jLabel3);
          jLabel3.setText(lang.get("lbl_Material_UOM_Variant"));
          jLabel3.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel3.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel3.setBounds(11, 83, 147, 21);
        }
        {
          jLabel4 = new JLabel4j_std();
          jDesktopPane1.add(jLabel4);
          jLabel4.setText(lang.get("lbl_Material_UOM_Numerator"));
          jLabel4.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel4.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel4.setBounds(11, 107, 147, 21);
        }
        {
          jLabel5 = new JLabel4j_std();
          jDesktopPane1.add(jLabel5);
          jLabel5.setText(lang.get("lbl_Material_UOM_Denominator"));
          jLabel5.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel5.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel5.setBounds(11, 129, 147, 21);
        }
        {
          jLabel6 = new JLabel4j_std();
          jDesktopPane1.add(jLabel6);
          jLabel6.setText(lang.get("lbl_Material_UOM"));
          jLabel6.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel6.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel6.setBounds(11, 34, 147, 21);
View Full Code Here

Examples of com.commander4j.gui.JLabel4j_std

              dispose();
            }
          });
        }
        {
          jLabel1 = new JLabel4j_std();
          jDesktopPane1.add(jLabel1);
          jLabel1.setText(lang.get("lbl_Material"));
          jLabel1.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel1.setBounds(49, 13, 70, 21);
        }
        {
          jTextFieldMaterial = new JTextField4j();
          jDesktopPane1.add(jTextFieldMaterial);
          jTextFieldMaterial.setText(lmaterial);
          jTextFieldMaterial.setBounds(126, 13, 126, 21);
          jTextFieldMaterial.setEnabled(false);
          jTextFieldMaterial.setEditable(false);
        }
        {
          jLabel3 = new JLabel4j_std();
          jDesktopPane1.add(jLabel3);
          jLabel3.setText(lang.get("lbl_Location_ID"));
          jLabel3.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel3.setBounds(49, 41, 70, 21);
        }
        {
          jTextFieldLocation = new JTextField4j();
          jDesktopPane1.add(jTextFieldLocation);
          jTextFieldLocation.setText(llocation);
          jTextFieldLocation.setBounds(126, 41, 126, 21);
          jTextFieldLocation.setEnabled(false);
          jTextFieldLocation.setEditable(false);
        }
        {
          ComboBoxModel<String> jComboBoxStatusModel = new DefaultComboBoxModel<String>(Common.locationStatusIncBlank);
          jComboBoxStatus = new JComboBox4j<String>();
          jDesktopPane1.add(jComboBoxStatus);
          jComboBoxStatus.setModel(jComboBoxStatusModel);
          jComboBoxStatus.setBounds(126, 69, 190, 23);
          jComboBoxStatus.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              jButtonUpdate.setEnabled(true);
            }
          });
        }
        {
          jLabel2 = new JLabel4j_std();
          jDesktopPane1.add(jLabel2);
          jLabel2.setText(lang.get("lbl_Material_Batch_Status"));
          jLabel2.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel2.setBounds(42, 69, 77, 21);
        }
View Full Code Here

Examples of com.commander4j.gui.JLabel4j_std

        jDesktopPane1.setBackground(Common.color_edit_properties);
        this.getContentPane().add(jDesktopPane1);
        jDesktopPane1.setPreferredSize(new Dimension(452, 140));
        jDesktopPane1.setLayout(null);
        {
          jLabelDescription = new JLabel4j_std();
          jDesktopPane1.add(jLabelDescription);
          jLabelDescription.setText(lang.get("lbl_Description"));
          jLabelDescription.setBounds(9, 175, 157, 19);
          jLabelDescription.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabelDescription.setHorizontalTextPosition(SwingConstants.RIGHT);
        }
        {
          jLabelID = new JLabel4j_std();
          jDesktopPane1.add(jLabelID);
          jLabelID.setText(lang.get("lbl_Printer_ID"));
          jLabelID.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabelID.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabelID.setBounds(9, 15, 157, 19);
        }
        {
          jLabelType = new JLabel4j_std();
          jDesktopPane1.add(jLabelType);
          jLabelType.setText(lang.get("lbl_Printer_Type"));
          jLabelType.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabelType.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabelType.setBounds(9, 81, 157, 19);
        }
        {

          jButtonUpdate = new JButton4j(Common.icon_update);
          jDesktopPane1.add(jButtonUpdate);
          jButtonUpdate.setText(lang.get("btn_Save"));
          jButtonUpdate.setBounds(152, 372, 110, 32);
          jButtonUpdate.setMnemonic(java.awt.event.KeyEvent.VK_S);
          jButtonUpdate.setEnabled(false);
          jButtonUpdate.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              printers.setDescription(jTextFieldDescription.getText());
              printers.setPrinterType(comboBoxPrinterType.getSelectedItem().toString());
              printers.setLanguage(JUtility.replaceNullStringwithBlank(comboBoxLanguage.getSelectedItem().toString()));
              printers.setIPAddress(jTextFieldIPAddress.getText());
              printers.setPort(jTextFieldPort.getText());
              printers.setGroupID(comboBox4jGroup.getSelectedItem().toString());
              printers.setDPI(comboBoxDPI.getSelectedItem().toString());

              printers.setPrinterEnabled(chckbxEnabled.isSelected());
              printers.setExportPath(jTextFieldExportPath.getText());
              printers.setEnableExport(chckbxEnableExport.isSelected());
              printers.setEnableDirectPrint(chckbxEnableDirectPrint.isSelected());
              printers.setExportFormat(JUtility.replaceNullStringwithBlank(comboBox4ExportFormat.getSelectedItem().toString()));

              printers.update();
              jButtonUpdate.setEnabled(false);
            }
          });
        }
        {
          jButtonClose = new JButton4j(Common.icon_close);
          jDesktopPane1.add(jButtonClose);
          jButtonClose.setText(lang.get("btn_Close"));
          jButtonClose.setBounds(388, 372, 110, 32);
          jButtonClose.setMnemonic(java.awt.event.KeyEvent.VK_C);
          jButtonClose.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              dispose();
            }
          });
        }
        {
          jTextFieldPrinterID = new JTextField4j();
          jTextFieldPrinterID.setFocusable(false);
          jDesktopPane1.add(jTextFieldPrinterID);
          jTextFieldPrinterID.setHorizontalAlignment(SwingConstants.LEFT);
          jTextFieldPrinterID.setEditable(false);
          jTextFieldPrinterID.setPreferredSize(new java.awt.Dimension(100, 20));
          jTextFieldPrinterID.setBounds(178, 13, 252, 21);
          jTextFieldPrinterID.setEnabled(false);
        }
        {
          comboBoxPrinterType = new JComboBox4j<String>();
          comboBoxPrinterType.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
              jButtonUpdate.setEnabled(true);
            }
          });
          comboBoxPrinterType.setModel(new DefaultComboBoxModel<String>(Common.printerTypes));
          jDesktopPane1.add(comboBoxPrinterType);
          comboBoxPrinterType.setPreferredSize(new java.awt.Dimension(40, 20));
          comboBoxPrinterType.setFocusCycleRoot(true);
          comboBoxPrinterType.setBounds(178, 79, 167, 21);

        }
        {
          jTextFieldDescription = new JTextField4j();
          jDesktopPane1.add(jTextFieldDescription);
          AbstractDocument doc = (AbstractDocument) jTextFieldDescription.getDocument();
          doc.setDocumentFilter(new JFixedSizeFilter(JDBControl.field_description));
          jTextFieldDescription.setPreferredSize(new java.awt.Dimension(40, 20));
          jTextFieldDescription.setFocusCycleRoot(true);
          jTextFieldDescription.setBounds(180, 173, 337, 21);
          jTextFieldDescription.addKeyListener(new KeyAdapter() {
            public void keyTyped(KeyEvent evt) {
              jButtonUpdate.setEnabled(true);
            }
          });
        }
        {
          jButtonHelp = new JButton4j(Common.icon_help);
          jDesktopPane1.add(jButtonHelp);
          jButtonHelp.setText(lang.get("btn_Help"));
          jButtonHelp.setBounds(276, 372, 100, 32);
          jButtonHelp.setMnemonic(java.awt.event.KeyEvent.VK_H);
        }
        {
          comboBoxDPI.setPreferredSize(new Dimension(40, 20));
          comboBoxDPI.setFocusCycleRoot(true);
          comboBoxDPI.setBounds(177, 145, 89, 21);
          comboBoxDPI.setModel(new DefaultComboBoxModel<String>(Common.printerDPI));
          comboBoxDPI.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
              jButtonUpdate.setEnabled(true);
            }
          });
          jDesktopPane1.add(comboBoxDPI);
        }
      }
     

      chckbxEnabled.addActionListener(new ActionListener() {
        public void actionPerformed(ActionEvent arg0) {
          jButtonUpdate.setEnabled(true);
        }
      });
      chckbxEnabled.setBounds(595, 11, 28, 23);
      jDesktopPane1.add(chckbxEnabled);
     
      JLabel4j_std label4jIPaddress = new JLabel4j_std();
      label4jIPaddress.setText(lang.get("lbl_IP_Address"));
      label4jIPaddress.setHorizontalTextPosition(SwingConstants.RIGHT);
      label4jIPaddress.setHorizontalAlignment(SwingConstants.RIGHT);
      label4jIPaddress.setBounds(9, 208, 157, 19);
      jDesktopPane1.add(label4jIPaddress);
     
      JLabel4j_std label4jPort = new JLabel4j_std();
      label4jPort.setText(lang.get("lbl_Port"));
      label4jPort.setHorizontalTextPosition(SwingConstants.RIGHT);
      label4jPort.setHorizontalAlignment(SwingConstants.RIGHT);
      label4jPort.setBounds(9, 241, 157, 19);
      jDesktopPane1.add(label4jPort);
     
      JLabel4j_std label4j_line = new JLabel4j_std();
      label4j_line.setText(lang.get("lbl_Language"));
      label4j_line.setHorizontalTextPosition(SwingConstants.RIGHT);
      label4j_line.setHorizontalAlignment(SwingConstants.RIGHT);
      label4j_line.setBounds(9, 114, 157, 19);
      jDesktopPane1.add(label4j_line);
     

      jTextFieldIPAddress.addKeyListener(new KeyAdapter() {
        @Override
        public void keyTyped(KeyEvent arg0) {
          jButtonUpdate.setEnabled(true);
        }
      });
      jTextFieldIPAddress.setText((String) null);
      jTextFieldIPAddress.setPreferredSize(new Dimension(40, 20));
      jTextFieldIPAddress.setFocusCycleRoot(true);
      jTextFieldIPAddress.setBounds(180, 206, 168, 21);
      jDesktopPane1.add(jTextFieldIPAddress);
     

      jTextFieldPort.addKeyListener(new KeyAdapter() {
        @Override
        public void keyTyped(KeyEvent e) {
          jButtonUpdate.setEnabled(true);
        }
      });
      jTextFieldPort.setText((String) null);
      jTextFieldPort.setPreferredSize(new Dimension(40, 20));
      jTextFieldPort.setFocusCycleRoot(true);
      jTextFieldPort.setBounds(179, 239, 168, 21);
      jDesktopPane1.add(jTextFieldPort);
     
      comboBoxLanguage.setModel(new DefaultComboBoxModel<String>(Common.printerLanguage));

      comboBoxLanguage.addActionListener(new ActionListener() {
        public void actionPerformed(ActionEvent e) {
          jButtonUpdate.setEnabled(true);
        }
      });
      comboBoxLanguage.setPreferredSize(new Dimension(40, 20));
      comboBoxLanguage.setFocusCycleRoot(true);
      comboBoxLanguage.setBounds(178, 112, 168, 21);
      jDesktopPane1.add(comboBoxLanguage);
     
      JLabel4j_std jTextFieldEnabled = new JLabel4j_std();
      jTextFieldEnabled.setText(lang.get("lbl_Enabled"));
      jTextFieldEnabled.setHorizontalTextPosition(SwingConstants.RIGHT);
      jTextFieldEnabled.setHorizontalAlignment(SwingConstants.RIGHT);
      jTextFieldEnabled.setBounds(426, 15, 157, 19);
      jDesktopPane1.add(jTextFieldEnabled);
     
      JLabel4j_std label4j_std = new JLabel4j_std();
      label4j_std.setText(lang.get("lbl_Group_ID"));
      label4j_std.setHorizontalTextPosition(SwingConstants.RIGHT);
      label4j_std.setHorizontalAlignment(SwingConstants.RIGHT);
      label4j_std.setBounds(9, 48, 157, 19);
      jDesktopPane1.add(label4j_std);
           
      comboBox4jGroup.setPreferredSize(new Dimension(40, 20));
      comboBox4jGroup.setFocusCycleRoot(true);
      comboBox4jGroup.setBounds(178, 46, 167, 21);
      comboBox4jGroup.setModel(new DefaultComboBoxModel<String>(Common.printerGroup));
      comboBox4jGroup.addActionListener(new ActionListener() {
        public void actionPerformed(ActionEvent e) {
          jButtonUpdate.setEnabled(true);
        }
      });
      jDesktopPane1.add(comboBox4jGroup);
     
      JLabel4j_std label4j_std1 = new JLabel4j_std();
      label4j_std1.setText("DPI");
      label4j_std1.setHorizontalTextPosition(SwingConstants.RIGHT);
      label4j_std1.setHorizontalAlignment(SwingConstants.RIGHT);
      label4j_std1.setBounds(9, 145, 157, 19);
      jDesktopPane1.add(label4j_std1);
     
      JLabel4j_std label4j_Export = new JLabel4j_std();
      label4j_Export.setText(lang.get("lbl_Export_Path"));
      label4j_Export.setHorizontalTextPosition(SwingConstants.RIGHT);
      label4j_Export.setHorizontalAlignment(SwingConstants.RIGHT);
      label4j_Export.setBounds(9, 276, 157, 19);
      jDesktopPane1.add(label4j_Export);
     

      chckbxEnableExport.setBounds(178, 272, 28, 23);
      jDesktopPane1.add(chckbxEnableExport);
     
      jTextFieldExportPath.setText("");
      jTextFieldExportPath.setPreferredSize(new Dimension(40, 20));
      jTextFieldExportPath.setFocusCycleRoot(true);
      jTextFieldExportPath.setBounds(205, 274, 385, 21);
      jDesktopPane1.add(jTextFieldExportPath);
     
     
      jButtonExportPathChooser.addActionListener(new ActionListener() {
        public void actionPerformed(ActionEvent e) {
          JFileChooser choosePath = new JFileChooser();

          try
          {
            File f = new File(new File("").getCanonicalPath());
            choosePath.setCurrentDirectory(f);
            choosePath.setSelectedFile(new File(jTextFieldExportPath.getText()));
            choosePath.setFileSelectionMode(JFileChooser.DIRECTORIES_ONLY);

            if (choosePath.showOpenDialog(jButtonExportPathChooser) == JFileChooser.APPROVE_OPTION)
            {
              File selectedFile;
              selectedFile = choosePath.getSelectedFile();

              if (selectedFile != null)
              {
                if (jTextFieldExportPath.getText().compareTo(selectedFile.getName()) != 0)
                {
                  jTextFieldExportPath.setText(selectedFile.getCanonicalPath());
                  jButtonUpdate.setEnabled(true);
                }
              }
            }

          }
          catch (Exception e2)
          {
          }
        }
      });
      jButtonExportPathChooser.setText("..");
      jButtonExportPathChooser.setBounds(587, 274, 17, 21);
      jDesktopPane1.add(jButtonExportPathChooser);
     
      JLabel4j_std label4j_Direct = new JLabel4j_std();
      label4j_Direct.setText(lang.get("lbl_Direct_Print"));
      label4j_Direct.setHorizontalTextPosition(SwingConstants.RIGHT);
      label4j_Direct.setHorizontalAlignment(SwingConstants.RIGHT);
      label4j_Direct.setBounds(9, 341, 157, 19);
      jDesktopPane1.add(label4j_Direct);
     
      chckbxEnableDirectPrint.setBounds(178, 337, 28, 23);
      jDesktopPane1.add(chckbxEnableDirectPrint);
     

      comboBox4ExportFormat.setPreferredSize(new Dimension(40, 20));
      comboBox4ExportFormat.setFocusCycleRoot(true);
      comboBox4ExportFormat.setBounds(177, 307, 89, 21);
      comboBox4ExportFormat.setModel(new DefaultComboBoxModel<String>(Common.printerExportFormat));
      jDesktopPane1.add(comboBox4ExportFormat);
     
      JLabel4j_std label4j_ExportFormat = new JLabel4j_std();
      label4j_ExportFormat.setText(lang.get("lbl_Interface_Format"));
      label4j_ExportFormat.setHorizontalTextPosition(SwingConstants.RIGHT);
      label4j_ExportFormat.setHorizontalAlignment(SwingConstants.RIGHT);
      label4j_ExportFormat.setBounds(9, 307, 157, 19);
      jDesktopPane1.add(label4j_ExportFormat);
      setEnabledObjects(printers.isExportEnabled());
     
    }
    catch (Exception e)
View Full Code Here

Examples of com.commander4j.gui.JLabel4j_std

    JDesktopPane desktopPane = new JDesktopPane();
    desktopPane.setBackground(Common.color_edit_properties);
    desktopPane.setBounds(0, 0, 861, 202);
    getContentPane().add(desktopPane);
   
    JLabel4j_std lblInspectionID = new JLabel4j_std(lang.get("lbl_Inspection_ID"));
    lblInspectionID.setBounds(8, 27, 87, 16);
    desktopPane.add(lblInspectionID);
    lblInspectionID.setHorizontalAlignment(SwingConstants.TRAILING);
   
    JLabel4j_std lblActivityID = new JLabel4j_std(lang.get("lbl_Activity_ID"));
    lblActivityID.setBounds(6, 67, 89, 16);
    desktopPane.add(lblActivityID);
    lblActivityID.setHorizontalAlignment(SwingConstants.TRAILING);
   
    JLabel4j_std lblTestID = new JLabel4j_std(lang.get("lbl_Test_ID"));
    lblTestID.setBounds(188, 105, 98, 16);
    desktopPane.add(lblTestID);
    lblTestID.setHorizontalAlignment(SwingConstants.TRAILING);
   
    textFieldInspectionID = new JTextField4j();
    textFieldInspectionID.setEnabled(false);
    textFieldInspectionID.setBounds(108, 22, 153, 28);
    desktopPane.add(textFieldInspectionID);
    textFieldInspectionID.setColumns(10);
   
    JLabel4j_std label4j_std = new JLabel4j_std(lang.get("lbl_Sequence_ID"));
    label4j_std.setBounds(8, 105, 87, 16);
    desktopPane.add(label4j_std);
    label4j_std.setHorizontalAlignment(SwingConstants.TRAILING);
   
    comboBoxTestID = new JComboBox4j<JDBQMDictionary>();
    comboBoxTestID.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent arg0) {
        enableSave();
      }
    });
    comboBoxTestID.setBounds(298, 102, 542, 27);
    desktopPane.add(comboBoxTestID);
   
    spinnerSequence = new JSpinner();
    spinnerSequence.setBounds(108, 102, 68, 28);
    ne = new JSpinner.NumberEditor(spinnerSequence);
    ne.getTextField().setFont(Common.font_std);
    spinnerSequence.setEditor(ne);
    spinnerSequence.setValue(100);
    spinnerSequence.addChangeListener(new ChangeListener() {
      public void stateChanged(ChangeEvent arg0) {
        enableSave();
      }
    });
    desktopPane.add(spinnerSequence);
   
    textFieldInspectionDescription = new JTextField4j();
    textFieldInspectionDescription.setEnabled(false);
    textFieldInspectionDescription.setBounds(377, 22, 463, 28);
    desktopPane.add(textFieldInspectionDescription);
    textFieldInspectionDescription.setColumns(10);
   

   
    btnSave = new JButton4j(lang.get("btn_Save"));
    btnSave.setEnabled(false);
    btnSave.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent arg0) {
        save();
      }
    });
    btnSave.setIcon(Common.icon_update);
    btnSave.setBounds(319, 154, 117, 29);
    desktopPane.add(btnSave);
   
    btnClose = new JButton4j(lang.get("btn_Close"));
    btnClose.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent arg0) {
        dispose();
      }
    });
    btnClose.setIcon(Common.icon_close);
    btnClose.setBounds(440, 154, 117, 29);
    desktopPane.add(btnClose);
   
    JLabel4j_std label4j_std_1 = new JLabel4j_std(lang.get("lbl_Description"));
    label4j_std_1.setHorizontalAlignment(SwingConstants.TRAILING);
    label4j_std_1.setBounds(273, 27, 92, 16);
    desktopPane.add(label4j_std_1);
   
    textFieldActivityID = new JTextField4j();
    textFieldActivityID.setEnabled(false);
    textFieldActivityID.setText("<dynamic>");
    textFieldActivityID.setColumns(10);
    textFieldActivityID.setBounds(108, 62, 153, 28);
    desktopPane.add(textFieldActivityID);
   
    JLabel4j_std label4j_std_2 = new JLabel4j_std(lang.get("lbl_Description"));
    label4j_std_2.setHorizontalAlignment(SwingConstants.TRAILING);
    label4j_std_2.setBounds(267, 67, 98, 16);
    desktopPane.add(label4j_std_2);
   
    textFieldActivityDescription = new JTextField4j();
    textFieldActivityDescription.setEnabled(false);
    textFieldActivityDescription.setColumns(10);
View Full Code Here

Examples of com.commander4j.gui.JLabel4j_std

        {
          dispose();
        }
      });

      lbl_ProcessOrder = new JLabel4j_std();
      jDesktopPane1.add(lbl_ProcessOrder);
      lbl_ProcessOrder.setText(lang.get("lbl_Process_Order"));
      lbl_ProcessOrder.setBounds(12, 10, 125, 21);
      lbl_ProcessOrder.setHorizontalAlignment(SwingConstants.TRAILING);

      JLabel4j_std lbl_Material = new JLabel4j_std();
      lbl_Material.setHorizontalAlignment(SwingConstants.TRAILING);
      lbl_Material.setText(lang.get("lbl_Material"));
      lbl_Material.setBounds(12, 40, 125, 21);
      jDesktopPane1.add(lbl_Material);

      JLabel4j_std lbl_ExpiryDate = new JLabel4j_std();
      lbl_ExpiryDate.setBounds(306, 100, 125, 21);
      lbl_ExpiryDate.setHorizontalAlignment(SwingConstants.RIGHT);
      lbl_ExpiryDate.setText(lang.get("lbl_Material_Batch_Expiry_Date"));
      jDesktopPane1.add(lbl_ExpiryDate);

      JLabel4j_std lbl_User_ID = new JLabel4j_std();
      lbl_User_ID.setHorizontalAlignment(SwingConstants.RIGHT);
      lbl_User_ID.setBounds(12, 227, 125, 21);
      lbl_User_ID.setText(lang.get("lbl_User_ID"));
      jDesktopPane1.add(lbl_User_ID);

      JLabel4j_std lbl_Production_Date = new JLabel4j_std(lang.get("lbl_Pallet_DOM"));
      lbl_Production_Date.setHorizontalAlignment(SwingConstants.TRAILING);
      lbl_Production_Date.setBounds(12, 100, 125, 21);
      jDesktopPane1.add(lbl_Production_Date);

      lbl_BatchNumber = new JLabel4j_std();
      lbl_BatchNumber.setBounds(12, 70, 125, 21);
      lbl_BatchNumber.setHorizontalTextPosition(SwingConstants.CENTER);
      lbl_BatchNumber.setHorizontalAlignment(SwingConstants.TRAILING);
      lbl_BatchNumber.setText(lang.get("lbl_Batch"));
      jDesktopPane1.add(lbl_BatchNumber);

      JLabel4j_std lbl_WorkstationID = new JLabel4j_std();
      lbl_WorkstationID.setText(lang.get("lbl_Workstation"));
      lbl_WorkstationID.setHorizontalAlignment(SwingConstants.RIGHT);
      lbl_WorkstationID.setBounds(306, 229, 125, 21);
      jDesktopPane1.add(lbl_WorkstationID);

      JTextField4j textField4j_ProcessOrder = new JTextField4j();
      textField4j_ProcessOrder.setEnabled(false);
      textField4j_ProcessOrder.setBounds(154, 10, 139, 21);
      textField4j_ProcessOrder.setText(labdat.getProcessOrder());
      jDesktopPane1.add(textField4j_ProcessOrder);

      JTextField4j textField4j_Material = new JTextField4j();
      textField4j_Material.setEnabled(false);
      textField4j_Material.setBounds(154, 38, 139, 21);
      textField4j_Material.setText(labdat.getMaterial());
      jDesktopPane1.add(textField4j_Material);

      JTextField4j textField4j_BatchNumber = new JTextField4j();
      textField4j_BatchNumber.setEnabled(false);
      textField4j_BatchNumber.setBounds(154, 68, 139, 21);
      textField4j_BatchNumber.setText(labdat.getBatchNumber());
      jDesktopPane1.add(textField4j_BatchNumber);

      JTextField4j textField4j_User_ID = new JTextField4j();
      textField4j_User_ID.setEnabled(false);
      textField4j_User_ID.setBounds(154, 227, 152, 21);
      textField4j_User_ID.setText(labdat.getUserID());
      jDesktopPane1.add(textField4j_User_ID);

      JTextField4j textField4j_WorkstationID = new JTextField4j();
      textField4j_WorkstationID.setEditable(false);
      textField4j_WorkstationID.setEnabled(false);
      textField4j_WorkstationID.setBounds(448, 227, 208, 21);
      textField4j_WorkstationID.setText(labdat.getWorkstationID());
      jDesktopPane1.add(textField4j_WorkstationID);

      JDateControl dateControl_DateofManufacture = new JDateControl();
      dateControl_DateofManufacture.setFont(new Font("Arial", Font.PLAIN, 11));
      dateControl_DateofManufacture.setEnabled(false);
      dateControl_DateofManufacture.setBounds(154, 98, 128, 25);
      dateControl_DateofManufacture.setDate(labdat.getDateofManufacture());
      jDesktopPane1.add(dateControl_DateofManufacture);

      JDateControl dateControl_ExpiryDate = new JDateControl();
      dateControl_ExpiryDate.setFont(new Font("Arial", Font.PLAIN, 11));
      dateControl_ExpiryDate.setEnabled(false);
      dateControl_ExpiryDate.setBounds(448, 98, 128, 25);
      dateControl_ExpiryDate.setDate(labdat.getExpirtDate());
      jDesktopPane1.add(dateControl_ExpiryDate);

      JTextField4j textField4j_Description = new JTextField4j();
      textField4j_Description.setEnabled(false);
      textField4j_Description.setBounds(305, 38, 351, 21);
      if (mat.getMaterialProperties(labdat.getMaterial()))
      {
        textField4j_Description.setText(mat.getDescription());
      }
      jDesktopPane1.add(textField4j_Description);

      JLabel4j_std lbl_ResourceID = new JLabel4j_std();
      lbl_ResourceID.setText(lang.get("lbl_Resource_Key"));
      lbl_ResourceID.setHorizontalAlignment(SwingConstants.RIGHT);
      lbl_ResourceID.setBounds(306, 70, 125, 21);
      jDesktopPane1.add(lbl_ResourceID);

      JTextField4j textField4j_Resource = new JTextField4j();
      textField4j_Resource.setEnabled(false);
      textField4j_Resource.setBounds(448, 68, 208, 21);
      textField4j_Resource.setText(labdat.getRequiredResource());
      jDesktopPane1.add(textField4j_Resource);

      JLabel4j_std lbl_Status = new JLabel4j_std();
      lbl_Status.setText(lang.get("lbl_Process_Order_Status"));
      lbl_Status.setHorizontalAlignment(SwingConstants.RIGHT);
      lbl_Status.setBounds(353, 10, 152, 21);
      jDesktopPane1.add(lbl_Status);

      JQuantityInput jFormattedTextFieldQuantity = new JQuantityInput(new BigDecimal("0"));
      jDesktopPane1.add(jFormattedTextFieldQuantity);
      jFormattedTextFieldQuantity.setFont(Common.font_std);
      jFormattedTextFieldQuantity.setHorizontalAlignment(SwingConstants.TRAILING);
      jFormattedTextFieldQuantity.setBounds(154, 198, 74, 21);
      jFormattedTextFieldQuantity.setEnabled(false);

      JTextField4j textField4j_Status = new JTextField4j();
      textField4j_Status.setEnabled(false);
      textField4j_Status.setBounds(517, 10, 139, 21);
      if (po.getProcessOrderProperties(labdat.getProcessOrder()))
      {
        textField4j_Status.setText(po.getStatus());
        jFormattedTextFieldQuantity.setText(po.getFullPalletQuantity());
      }
      jDesktopPane1.add(textField4j_Status);

      JScrollPane scrollPane = new JScrollPane();
      scrollPane.setBounds(154, 262, 429, 113);
      jDesktopPane1.add(scrollPane);

      list = new JList4j<JDBListData>();
      list.addListSelectionListener(new ListSelectionListener()
      {
        public void valueChanged(ListSelectionEvent arg0)
        {
          enableButtons();
        }
      });
      list.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
      scrollPane.setViewportView(list);

      JButton4j JButtonRefresh = new JButton4j(Common.icon_refresh);
      JButtonRefresh.addActionListener(new ActionListener()
      {
        public void actionPerformed(ActionEvent arg0)
        {
          populateList("Pack");
        }
      });
      JButtonRefresh.setText(lang.get("btn_Refresh"));
      JButtonRefresh.setMnemonic('0');
      JButtonRefresh.setBounds(222, 387, 130, 30);
      jDesktopPane1.add(JButtonRefresh);

      JLabel4j_std label4j_Production_UOM = new JLabel4j_std((String) null);
      label4j_Production_UOM.setHorizontalAlignment(SwingConstants.TRAILING);
      label4j_Production_UOM.setBounds(12, 165, 125, 21);
      label4j_Production_UOM.setText(lang.get("lbl_Production_UOM"));
      jDesktopPane1.add(label4j_Production_UOM);

      JLabel4j_std label4j_std_Base_UOM = new JLabel4j_std((String) null);
      label4j_std_Base_UOM.setHorizontalAlignment(SwingConstants.TRAILING);
      label4j_std_Base_UOM.setBounds(12, 132, 125, 21);
      label4j_std_Base_UOM.setText(lang.get("lbl_Base_UOM"));
      jDesktopPane1.add(label4j_std_Base_UOM);

      JTextField4j textField4j_Prod_EAN = new JTextField4j();
      textField4j_Prod_EAN.setHorizontalAlignment(SwingConstants.CENTER);
      textField4j_Prod_EAN.setEnabled(false);
      textField4j_Prod_EAN.setText(labdat.getProdEAN());
      textField4j_Prod_EAN.setBounds(315, 165, 139, 21);
      jDesktopPane1.add(textField4j_Prod_EAN);

      JTextField4j textField4j_Base_EAN = new JTextField4j();
      textField4j_Base_EAN.setHorizontalAlignment(SwingConstants.CENTER);
      textField4j_Base_EAN.setEnabled(false);
      textField4j_Base_EAN.setText(labdat.getBaseEAN());
      textField4j_Base_EAN.setBounds(315, 132, 139, 21);
      jDesktopPane1.add(textField4j_Base_EAN);

      JTextField4j textField4j_Prod_UOM = new JTextField4j();
      textField4j_Prod_UOM.setHorizontalAlignment(SwingConstants.CENTER);
      textField4j_Prod_UOM.setEnabled(false);
      textField4j_Prod_UOM.setText(labdat.getProdUom());
      textField4j_Prod_UOM.setBounds(258, 165, 51, 21);
      jDesktopPane1.add(textField4j_Prod_UOM);

      JTextField4j textField4j_Prod_Variant = new JTextField4j();
      textField4j_Prod_Variant.setHorizontalAlignment(SwingConstants.CENTER);
      textField4j_Prod_Variant.setEnabled(false);
      textField4j_Prod_Variant.setText(labdat.getProdVariant());
      textField4j_Prod_Variant.setBounds(472, 165, 51, 21);
      jDesktopPane1.add(textField4j_Prod_Variant);

      JTextField4j textField4j_Base_Variant = new JTextField4j();
      textField4j_Base_Variant.setHorizontalAlignment(SwingConstants.CENTER);
      textField4j_Base_Variant.setEnabled(false);
      textField4j_Base_Variant.setText(labdat.getBaseVariant());
      textField4j_Base_Variant.setBounds(472, 132, 51, 21);
      jDesktopPane1.add(textField4j_Base_Variant);

      JTextField4j textField4j_Base_UOM = new JTextField4j();
      textField4j_Base_UOM.setHorizontalAlignment(SwingConstants.CENTER);
      textField4j_Base_UOM.setEnabled(false);
      textField4j_Base_UOM.setText(labdat.getBaseUom());
      textField4j_Base_UOM.setBounds(258, 132, 51, 21);
      jDesktopPane1.add(textField4j_Base_UOM);

      JLabel4j_std label4j_std_Pallet_Quantity = new JLabel4j_std((String) null);
      label4j_std_Pallet_Quantity.setText(lang.get("lbl_Pallet_Quantity"));
      label4j_std_Pallet_Quantity.setHorizontalAlignment(SwingConstants.TRAILING);
      label4j_std_Pallet_Quantity.setBounds(12, 198, 125, 21);
      jDesktopPane1.add(label4j_std_Pallet_Quantity);

      JLabel4j_std label4j_std_1 = new JLabel4j_std((String) null);
      label4j_std_1.setText("x");
      label4j_std_1.setHorizontalAlignment(SwingConstants.CENTER);
      label4j_std_1.setBounds(232, 165, 22, 21);
      jDesktopPane1.add(label4j_std_1);

      JLabel4j_std label4j_std_2 = new JLabel4j_std((String) null);
      label4j_std_2.setText("x");
      label4j_std_2.setHorizontalAlignment(SwingConstants.CENTER);
      label4j_std_2.setBounds(232, 132, 22, 21);
      jDesktopPane1.add(label4j_std_2);

      JLabel4j_std label4j_std_3 = new JLabel4j_std((String) null);
      label4j_std_3.setText("/");
      label4j_std_3.setHorizontalAlignment(SwingConstants.CENTER);
      label4j_std_3.setBounds(453, 165, 22, 21);
      jDesktopPane1.add(label4j_std_3);

      JLabel4j_std label4j_std_4 = new JLabel4j_std((String) null);
      label4j_std_4.setText("/");
      label4j_std_4.setHorizontalAlignment(SwingConstants.CENTER);
      label4j_std_4.setBounds(453, 132, 22, 21);
      jDesktopPane1.add(label4j_std_4);

      JTextField4j textField4j_Prod_Quantity = new JTextField4j();
      textField4j_Prod_Quantity.setEnabled(false);
      textField4j_Prod_Quantity.setHorizontalAlignment(SwingConstants.TRAILING);
      textField4j_Prod_Quantity.setBounds(154, 132, 74, 21);
      textField4j_Prod_Quantity.setText(labdat.getProdQuantity().toString());
      jDesktopPane1.add(textField4j_Prod_Quantity);

      JTextField4j textField4j_Base_Quantity = new JTextField4j();
      textField4j_Base_Quantity.setEnabled(false);
      textField4j_Base_Quantity.setHorizontalAlignment(SwingConstants.TRAILING);
      textField4j_Base_Quantity.setBounds(154, 165, 74, 21);
      textField4j_Base_Quantity.setText(labdat.getBaseQuantity().toString());
      jDesktopPane1.add(textField4j_Base_Quantity);

      JTextField4j textField4j_Pallet_UOM = new JTextField4j();
      textField4j_Pallet_UOM.setEnabled(false);
      textField4j_Pallet_UOM.setHorizontalAlignment(SwingConstants.CENTER);
      textField4j_Pallet_UOM.setBounds(258, 198, 51, 21);
      textField4j_Pallet_UOM.setText(labdat.getProdUom());
      jDesktopPane1.add(textField4j_Pallet_UOM);

      JLabel4j_std label4j_std = new JLabel4j_std((String) null);
      label4j_std.setText("x");
      label4j_std.setHorizontalAlignment(SwingConstants.CENTER);
      label4j_std.setBounds(232, 198, 22, 21);
      jDesktopPane1.add(label4j_std);

      JLabel4j_std lbl_ReportID = new JLabel4j_std((String) null);
      lbl_ReportID.setText(lang.get("lbl_Report_ID"));
      lbl_ReportID.setHorizontalAlignment(SwingConstants.TRAILING);
      lbl_ReportID.setBounds(306, 198, 125, 21);
      jDesktopPane1.add(lbl_ReportID);

      JTextField4j textField4j_Report_ID = new JTextField4j();
      textField4j_Report_ID.setEditable(false);
      textField4j_Report_ID.setText(labdat.getModuleID());
View Full Code Here

Examples of com.commander4j.gui.JLabel4j_std

              dispose();
            }
          });
        }
        {
          jLabel1 = new JLabel4j_std();
          jDesktopPane1.add(jLabel1);
          jLabel1.setText(lang.get("lbl_Material"));
          jLabel1.setBounds(0, 11, 91, 21);
          jLabel1.setHorizontalAlignment(SwingConstants.TRAILING);
        }
        {
          jTextFieldMaterial = new JTextField4j();
          jDesktopPane1.add(jTextFieldMaterial);
          jTextFieldMaterial.setBounds(99, 11, 141, 21);
        }
        {
          jLabel3 = new JLabel4j_std();
          jDesktopPane1.add(jLabel3);
          jLabel3.setText(lang.get("lbl_Material_Batch"));
          jLabel3.setBounds(0, 44, 91, 21);
          jLabel3.setHorizontalAlignment(SwingConstants.TRAILING);
        }
        {
          jTextFieldBatch = new JTextField4j();
          jDesktopPane1.add(jTextFieldBatch);
          jTextFieldBatch.setBounds(99, 44, 141, 21);
        }
        {
          jLabel10 = new JLabel4j_std();
          jDesktopPane1.add(jLabel10);
          jLabel10.setText(lang.get("lbl_Sort_By"));
          jLabel10.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel10.setBounds(0, 178, 91, 21);
        }
        {
          ComboBoxModel<String> jComboBoxSortByModel = new DefaultComboBoxModel<String>(new String[] { "MATERIAL", "BATCH_NUMBER", "STATUS", "EXPIRY_DATE" });
          jComboBoxSortBy = new JComboBox4j<String>();
          jDesktopPane1.add(jComboBoxSortBy);
          jComboBoxSortBy.setModel(jComboBoxSortByModel);
          jComboBoxSortBy.setBounds(99, 176, 141, 23);
        }
        {
          jLabel5 = new JLabel4j_std();
          jDesktopPane1.add(jLabel5);
          jLabel5.setText(lang.get("lbl_Material_Batch_Status"));
          jLabel5.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel5.setBounds(0, 79, 91, 21);
        }
        {
          ComboBoxModel<String> jComboBoxStatusModel = new DefaultComboBoxModel<String>(Common.batchStatusIncBlank);
          jComboBoxStatus = new JComboBox4j<String>();
          jDesktopPane1.add(jComboBoxStatus);
          jComboBoxStatus.setModel(jComboBoxStatusModel);
          jComboBoxStatus.setBounds(99, 77, 141, 23);
        }
        {
          jToggleButtonSequence = new JToggleButton();
          jDesktopPane1.add(jToggleButtonSequence);
          jToggleButtonSequence.setBounds(246, 178, 21, 21);
          jToggleButtonSequence.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              setSequence(jToggleButtonSequence.isSelected());
            }
          });
        }

        {
          jButtonLookupMaterial = new JButton4j();
          jButtonLookupMaterial.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
              JLaunchLookup.dlgAutoExec = false;
              JLaunchLookup.dlgCriteriaDefault = "";
              if (JLaunchLookup.materials())
              {
                jTextFieldMaterial.setText(JLaunchLookup.dlgResult);
              }
            }
          });
          jButtonLookupMaterial.setBounds(246, 11, 21, 21);
          jDesktopPane1.add(jButtonLookupMaterial);
        }

        {
          jButtonLookupBatch = new JButton4j();
          jButtonLookupBatch.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
              JLaunchLookup.dlgCriteriaDefault = jTextFieldMaterial.getText();
              JLaunchLookup.dlgAutoExec = true;
              if (JLaunchLookup.materialBatches())
              {
                jTextFieldBatch.setText(JLaunchLookup.dlgResult);
              }

            }
          });
          jButtonLookupBatch.setBounds(246, 44, 21, 21);
          jDesktopPane1.add(jButtonLookupBatch);
        }

        {
          expiryFrom.setBounds(120, 110, 125, 25);
          expiryFrom.setEnabled(false);
          jDesktopPane1.add(expiryFrom);
        }

        {
          expiryTo.setBounds(120, 143, 125, 25);
          expiryTo.setEnabled(false);
          jDesktopPane1.add(expiryTo);
        }

        {
          jLabel5_1 = new JLabel4j_std();
          jLabel5_1.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel5_1.setText(lang.get("lbl_Material_Batch_Expiry_From"));
          jLabel5_1.setBounds(0, 110, 91, 21);
          jDesktopPane1.add(jLabel5_1);
        }

        {
          jLabel5_2 = new JLabel4j_std();
          jLabel5_2.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel5_2.setText(lang.get("lbl_Material_Batch_Expiry_To"));
          jLabel5_2.setBounds(0, 147, 91, 21);
          jDesktopPane1.add(jLabel5_2);
        }

        {
          jCheckBoxFrom = new JCheckBox4j();
          jCheckBoxFrom.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
              if (jCheckBoxFrom.isSelected())
              {
                expiryFrom.setEnabled(true);
                calendarButtonexpiryFrom.setEnabled(true);
              }
              else
              {
                expiryFrom.setEnabled(false);
                calendarButtonexpiryFrom.setEnabled(false);
              }
            }
          });
          jCheckBoxFrom.setBackground(new Color(255, 255, 255));
          jCheckBoxFrom.setBounds(99, 110, 21, 21);
          jDesktopPane1.add(jCheckBoxFrom);
        }

        {
          jCheckBoxTo = new JCheckBox4j();
          jCheckBoxTo.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
              if (jCheckBoxTo.isSelected())
              {
                expiryTo.setEnabled(true);
                calendarButtonexpiryTo.setEnabled(true);
              }
              else
              {
                expiryTo.setEnabled(false);
                calendarButtonexpiryTo.setEnabled(false);
              }
            }
          });
          jCheckBoxTo.setBackground(new Color(255, 255, 255));
          jCheckBoxTo.setBounds(99, 143, 21, 21);
          jDesktopPane1.add(jCheckBoxTo);
        }

        {
          jButtonAdd = new JButton4j(Common.icon_add);
          jButtonAdd.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_ADMIN_MATERIAL_BATCH_ADD"));
          jButtonAdd.addActionListener(new ActionListener() {
            public void actionPerformed(final ActionEvent e) {
              addRecord();
            }
          });
          jButtonAdd.setText(lang.get("btn_Add"));
          jButtonAdd.setMnemonic(lang.getMnemonicChar());
          jButtonAdd.setBounds(293, 39, 126, 32);
          jDesktopPane1.add(jButtonAdd);
        }

        {
          jStatusText = new JLabel4j_std();
          jStatusText.setForeground(new Color(255, 0, 0));
          jStatusText.setBackground(Color.GRAY);
          jStatusText.setBounds(0, 559, 425, 21);
          jDesktopPane1.add(jStatusText);
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.