Results 1 to 3 of 3
- 08-05-2011, 06:54 AM #1
How to pass the value(lift) from one page(SCL.java) to another page(MFCP.java)
Hi,
How to pass values from one page(SCL.java) to another page(MFCP.java)
I created new file by
selecting Swing GUI Forums in categories & JFrames in file types.
May i know how to pass the "lift value" to another page (MFCP.java).
Java Code:import javax.swing.*; import javax.swing.table.*; import java.sql.*; public class SCL extends javax.swing.JFrame { Object[] data = new Object[5]; String s[]={"Count","Rule","Suport","Confidence","Lift"}; int num[]= new int[20]; int number[]= new int[20]; float f2[]= new float[20]; float f3[]= new float[20]; float f1[]= new float[20]; String Rule[]={"FUP1- N","FUP1-Y","MUP1-N","MUP1-Y","FUP2-N","FUP2-Y","MUP2-N","MUP2-Y","FUP3-N","FUP3-Y","MUP3-N","MUP3-Y","FUP4-N","FUP4-Y","MUP4-N","MUP4-Y","FUP5-N","FUP5-Y","MUP5-N","MUP5-Y"}; String sql[]=new String[60]; int Supportnum; int i,a,j,k,b,countnum,b1; DefaultTableModel d = new DefaultTableModel(); JTable jtable1 = new JTable(d); JFrame frame = new JFrame(); { setVisible(true); setSize(400, 600); setLocation(100, 100); setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); for(int c = 0; c < 5; c++) { d.addColumn(s[c]); }With Regards and Respects,Java Code:for(j=20,k=0,countnum=1;j<=39&&k<=19&&countnum<=20;j++,k++,countnum++) { rs[j]=st1.executeQuery(sql[j]); System.out.println("Inside for loop "+j); { if (rs[j].next()) { number[k] = rs[j].getInt(1); float x,y,z,lift,x1,x2,y1; x1=number[k]; x2=Supportnum; x=x1/x2; y1=num[k]; y=y1/x2; z=(f1[k]/x2); [COLOR="darkred"] lift=(x/(y*z));[/COLOR] data[0]=countnum; data[1]=Rule[k]; data[2]=number[k]+"/"+Supportnum; data[3]=number[k]+"/"+num[k]; data[4]=lift; } d.addRow(data); rs[j].close(); }
Nandhini.Last edited by nandhinianand; 08-05-2011 at 08:02 AM.
- 08-07-2011, 08:12 AM #2
Member
- Join Date
- Aug 2011
- Posts
- 7
- Rep Power
- 0
Refer this page:
passing data from one jframe to another
- 08-07-2011, 09:50 PM #3
Similar Threads
-
How to Export web page(jsp page) to excel using jsp or servlets or javascript
By techsing14 in forum JavaServer Pages (JSP) and JSTLReplies: 3Last Post: 05-25-2011, 11:08 AM -
how to pass the date selected from the combo boxes on the page to the database ?
By karter in forum NetBeansReplies: 0Last Post: 04-27-2011, 10:34 AM -
Pass variable from program to web page
By snoopy11 in forum New To JavaReplies: 2Last Post: 03-13-2011, 04:10 PM -
How to pass mysql string through a url parameter to a detail page query
By kwesiaryee in forum New To JavaReplies: 1Last Post: 08-22-2008, 06:28 PM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks