1

I'm trying to plan our first web page using Java. We started looking at using JavaScript but since the table isn't static, I don't think we can use it. I want to use Netbeans and eventually junit to test.

Running web page:

checkbox list-> table for data entry/add/delete table columns -> send (all) data to DB

I noticed the checkbox in the link uses swing and awt. Is that ok to use for a webpage? A friend suggested swing and JPanel are better (more up-to-date), and I was looking at AWT also, but I haven't found anything about them yet. I found an example for JTable; hopefully that's good to use for a web page too. I was going to use a MVC pattern later. Do you have any other examples?

Community
  • 1
  • 1
Michele
  • 3,617
  • 12
  • 47
  • 81
  • 1
    I would suggest going through the http://docs.oracle.com/javase/tutorial/uiswing/components/applet.html tutorial to learn how to use swing in java applets. This tutorial to learn how to use applets in general : http://docs.oracle.com/javase/tutorial/deployment/applet/index.html. Alternatively you can use JavaScript with something like Ajax for the web page which would communicate with a server-side Java application. – SamYonnou Mar 27 '14 at 15:55
  • I simplified the question, as requested by @aldux. – Michele Mar 27 '14 at 16:03
  • So if I create a Web Application with an index.html and then a couple classes to make the CheckBox selector for column names with swing and awt like < http://alturl.com/u38dw >, and the table with JTable like < http://alturl.com/t67zq >, can I call them from my index.html and have users run the web page from remote locations, checking the checkboxes and entering data in columns? – Michele Mar 28 '14 at 15:22
  • @Sam Yonnou - thanks for the idea for the tutorials. It was very helpful. Much better than finding random examples online. – Michele Mar 28 '14 at 15:28
  • 1
    If it's an webapp, try using plain JSP first, so you get how an webapp works, how requests and responses interact, how to write code for server and client side and understanding the differences. Swing, AWT, Jpanel are mostly used for stand-alone applications. – aldux Apr 01 '14 at 21:27

0 Answers0