Find Us On: Facebook Twitter Rss Feed Blog
Need To Register? Sign Up Login

Pool Project

msladona
msladona 


Need to know if you can help me complete my course project. There are a couple of things I need help with. First I need help with making my Jlabel print on 2 lines instead of one long line. These are the two lines I need help with. labelContractors.setText(file.getName()+" does not exist yet. It will be created when you add a contractor!"); lblCustomerStatus.setText("Customer.txt does not exist yet. It will be created when you add a customer!"); The other thing I would like help with is creating a menu bar for the Customer and Contractor tab where the action could be selected as follows: "Select Action to Perform" (KeyEvent_S) "Add New Customer" (KeyEvent_A) "Edit Customer" (KeyEvent_E) "Delete Customer" (KeyEvent_D) (Same for Contractor tab) The last thing I need help with is creating a report tab and menu. The report menu would need the following: "Generate Report" (KeyEvent_R) Would like to be able to generate a report that list all customers and one that would list all contractors. Attachments Tags
Clarifications

Answers

Java - Pool Project - Solution

dickersonka
dickersonka 



Attached is the source including the updates for menu items, Report tab and generation and multiple lines for the label text. Attachments
mainPackage.zip (10 K) Download
Preview
JButton btnAddCustomer; private JButton btnClose; private JButton btnDeleteFile; private JLabel labelStatus; /** * Launch the application. */ String labelStatusText; boolean fileCreated; //List of states for combobox, included a small sample String[] validStates = {"FL", "GA", "GU", "HI", "ID", "IL",

Preview
//If the file is not created create a new one try { File file = new File(MainWindow.CUSTOMER_FILE); boolean success = file.createNewFile(); // Create file if it does not exist if(success)// File did not exist and was created { PrintWriter out =

Preview
/** * @param args */ public static void

Preview
JPanel panel = new JPanel(); tabbedPane.addTab("General", null, panel, null); panel.setLayout(null); JButton btnExit = new JButton("Exit"); btnExit.setMnemonic('E'); btnExit.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent arg0) { System.exit(0); } }); btnExit.setBounds(244, 24, 89, 23); panel.add(btnExit); //Create the

Screenshots
Purchase Answer