| Author |
passing parameters between servlets and applets
|
aparajita kulkarni
Greenhorn
Joined: Sep 22, 2004
Posts: 1
|
|
hello, Actually i want to retriew data from MSAccess database in applets. because applets cannot communicate with MSAccess DB so i thought of using servlets in between. now i want to retriew data from DB to servlets then i want to pass those values to applets and any changes made to then will be sent back to servlet and servlet will update the DB. so can any one send me sample code where servlets read data from MSAccess and fwd it to applets. give clear idea how can i do it. aparajita
|
 |
Himanshu Bisht
Ranch Hand
Joined: Aug 27, 2004
Posts: 96
|
|
hi this might help //connection to db dbConnection dbConn = new dbConnection(); Statement stmta = dbConn.connect(); //ur query String query1="select prod_id from product_tbl where prod_type='"+type+"' and prod_width='"+width+"' and prod_micron='"+micron+"' "; //resultset rs1=stmta.executeQuery(query1); //accessing rs if(rs1.next()) { id=(String)rs1.getString("prod_id"); ...... ...... } now u have the values u can pass it to applet
|
 |
Jeroen Wenting
Ranch Hand
Joined: Oct 12, 2000
Posts: 5093
|
|
the idea is that you try yourself and then come to us with specific questions. People are not generally inclined to do all your work for you unless you pay us consultancy fees.
|
42
|
 |
 |
|
|
subject: passing parameters between servlets and applets
|
|
|