private JPanel transtab() {
		JPanel trans = new JPanel();
		trans.setLayout(null);
		JButton newtrans, viewtrans;
		newtrans = new JButton("New Transaction");
		viewtrans = new JButton("View Transactions");

		newtrans.addActionListener(new ActionListener() {

			@Override
			public void actionPerformed(ActionEvent arg0) {

				setVisible(false);

				String accno = getaccno();
				if (accno == null || accno.trim().length() == 0)
					setVisible(true);
				else {
					ResultSet rs = query("select * from customer where accno = "
							+ accno);
					try {
						if (!rs.next()) {
							JOptionPane.showMessageDialog(null,
									"Account does not exist with this No.", "",
									JOptionPane.ERROR_MESSAGE);
							setVisible(true);
						} else
							new EditCustomer(Integer.parseInt(accno), 1);

					} catch (HeadlessException | SQLException e) {
						e.printStackTrace();
					}

				}

			}
		});

		viewtrans.addActionListener(new ActionListener() {

			@Override
			public void actionPerformed(ActionEvent arg0) {
				setVisible(false);
				String accno = getaccno();
				if (accno == null || accno.trim().length() == 0)
					setVisible(true);
				else {
					try {
						ResultSet rs = query("select * from customer where accno = "
								+ accno);

						if (!rs.next()) {
							JOptionPane.showMessageDialog(null,
									"Account does not exist with this No.", "",
									JOptionPane.ERROR_MESSAGE);
							setVisible(true);
						} else

							new ViewFrame().viewFrame(1,
									Integer.parseInt(accno), 1,username);

					} catch (HeadlessException | SQLException e) {
						e.printStackTrace();
					}
				}
			}
		});

		newtrans.setBounds(100, 80, 200, 30);
		viewtrans.setBounds(100, 120, 200, 30);

		trans.add(newtrans);
		trans.add(viewtrans);
		return trans;

	}