Table

Table

How i generate table in showMessageDialog. I want that i creat a table and run in showMessageDialogeprint("cprint("code sample");ode sample");

View Answers

January 29, 2011 at 5:09 PM

Hi Friend,

Try this:

import javax.swing.*;
public class MultiplicationTable{
public static void main(String args[]){
    StringBuffer buffer=new StringBuffer();
String number=JOptionPane.showInputDialog(null,"Enter number whose table is to be displayed");
int n=Integer.parseInt(number);
int result;
for (int a = 1; a <= 10; a++)
{
result = n * a;
buffer.append(n);
buffer.append(" * ");
buffer.append(a);
buffer.append(" = ");
buffer.append(result);
buffer.append("\n");
}
JOptionPane.showMessageDialog(null,buffer.toString());
}
}

Thanks









Related Tutorials/Questions & Answers:
table
table  multiplicatyion table
TABLE
TABLE   Why doesn't <TABLE WIDTH="100%"> use the full browser width
Advertisements
Table
Table  How i generate table in showMessageDialog. I want that i creat a table and run in showMessageDialogeprint("cprint("code sample");ode sample
Table
Table  How I generate table in showMessageDialog. E.g 3X1=3 3X2=6 3X3=9print("code sample
Table
Table  How i generate table in showMessageDialog. I want to creat a table and run in showMessageDialoge. Pl make a table programe which run..., JOptionpane, Integer.parseInt. Please use only these above methods to make table
table
input from oracle table(my database table..) This is a very important table of my
table
table  Hi..I have a list of links which links to a table in the same page.If I click first link the table is displayed at the top, likewise if i click the last link the table is displayed at the last,i dont know how to set
Table
Table  How i generate table in JOptionpane.showMessageDialog... advance coding but i want u make the table using JOptionpane.showMessageDialog, import.javax.swing int Integer.parseInt(). Thats my limit. Pl generata a table
table?
table?  Hi, how could i make a table in javascript, which would look like this: AA CODON Number /1000 Fraction .. (this row... can't figure out, how to construct a table,with two fixed columns, one that reads
Table
Table  Why u dont understand sir?? I want to make a table program which generate a table on showMessageDialog. I have learnt these methods until now... methods to be used. Write a table program which use only and only these above methods
Table
Table  How i create table on showMessageDialog using JOptionpane and Integer.parseInt. No other method to use. Pl make a program which generate 5X1=5 5X2=10 5X3=15   Hi Friend, Try this: import javax.swing.*; import
table in java
table in java  please l want to make table and insert by user
table header
table header  how set the header to the TableModel
HEAP table
HEAP table  hiii, What is HEAP table?   hello,ADS_TO_REPLACE_1 This type of table is stored in the memory. Speed of execution of this table is very commendable
center a table
center a table  How do I center a table
SQLite Table
SQLite Table  how to create a table in sqlite xcode with a fix number of items
Multiplication table
Design and develop Multiplication table in Net beans  Design and develop a program that will print a multiplication table. The program should: Ask... table.   import java.util.Scanner; class Multiplication { public static
table in java
table in java  Could any one make compiler in java please reply me
table in java
table in java  Could any one make compiler in java please reply me
table in java
table in java  Could any one make compiler in java please reply me
Hash table
Hash table  Hi guys.. I have question about hash table How to implement a hash table of English words? with these methodsADS_TO_REPLACE_1 ïâ??· A method put(s), which adds the string s to the table, if it is not already
multipications table
.. Table (decide if this is HTML or JSP) Table shows the multipications table up... will be: 1 2 3 2 4 6 3 6 9 Also, add a button to Table so that pressing this button will make the table disappear. helppppp don't know were to begin plea
Multiplication table
Multiplication table Net Beans  Using Net beans Design and develop... for ending number than Display that particular multiplication table   ...(String args[]) { int n; System.out.print("Enter the number whose table
jsf table
a table named as customer. customer table has following columns : customerid(varchar... table in this index.jsp file.this jsf file should be able to retrieve the data from... the table customer.   Hello Friend, Please visit the following link
Table Creation
Table Creation  hi! I want a table which looks like following can... to make such table? plz help.........  ...","Oct","Nov","Dec" }; JTable table = new JTable(rowData, columnNames
Table Creation
Table Creation  create the table for the following fields.its very urgent for me.plz help me S.No,Category( From the home page),Name of the Candidate( After registering and after selecting the category),Age,Title of the project
Multiplication table
number than Display that particular multiplication table   import...[]) { int n; System.out.print("Enter the number whose table is to be displayed
Adding a flex table in another flex table column
Adding a flex table in another flex table column  how to add a flex table in another flex table column
Drop Table
Drop Table       Drop Table in SQL get rid of an object or table from the database. Using a drop Query get rid of all the rows deleted from the table and the structure is removed
MYSQL - mysql copy table to another table example by creating new table
MYSQL - mysql copy table to another table example by creating new table  Hi, I have a table with many fields and hue data is in it. I want to create a new table with all the data from this table. How to create a new table
how to use stringtokenizer on table? and display in table format.
display result in row format  how to use stringtokenizer on table? and display in table format
mysql select into table from another table example
mysql select into table from another table example  Can you suggest the correct example of select into table from another table example in MySQL... from one table into another table. Check the example at MySQLselect into new
how to use stringtokenizer on table? and display in table format.
how to use stringtokenizer on table? and display in table format.  table is retrieved from mysql database and each row contains data like(java,c,c++,.net
how to insert one table to anothere table
how to insert one table to anothere table  i have insert the record one table then i retrve the value of that table i insert one value at a time
Adding checkbox in table using that delete table rows
Adding checkbox in table using that delete table rows  I need coding for how to add checkbox in table,the table data from database.Using that checkbox select more than than one rows,and using delete button i want to delete
Table Maintenance Statements
Table Maintenance Statements   ... TABLE, BACKUP TABLE, CHECK TABLE, CHECKSUM TABLE, OPTIMIZE TABLE, REPAIR TABLE, RESTORE TABLE Syntax. ANALYZE TABLE Syntax The general syntax of ANALYZE TABLE
Extjs Table Sorting
Extjs Table Sorting  how is it possible to do the table sort in extjs
What is Mutating Table?
What is Mutating Table?  What is Mutating Table
Extjs Table Sorting
Extjs Table Sorting  how is it possible to do the table sort in extjs
Extjs Table Sorting
Extjs Table Sorting  how is it possible to do the table sort in extjs
DROP a table and TRUNCATE
DROP a table and TRUNCATE   What are the differences between DROP a table and TRUNCATE a table
update one table from another table
update one table from another table  hello, i need to update one table fields by using another table fields. I have to tables Products.... for example TotalQuantity field from Products table should be updated if i
syntax for create a table
syntax for create a table  syntax for create a table
HTML Table in javascript
HTML Table in javascript  hi all, how to add last row with sum in table using javascript
disallow NULL values in a table.
disallow NULL values in a table.  How do I disallow NULL values in a table
align a table to the right (or left).
align a table to the right (or left).  How do I align a table to the right (or left
align a table to the right (or left).
align a table to the right (or left).  How do I align a table to the right (or left
Getting mysql table in textbox
Getting mysql table in textbox  how to get mysql table values into textbox in java using ajax and servlets
Hibernate Temporary Table
Hibernate Temporary Table   How can i create temporary table in Hibernate
Mysql Alter Table Syntax
Mysql Alter Table Syntax       Mysql Alter Table is used to redefine the existing table. ALTER TABLE tbl_name ADD [COLUMN] col_name column_definition

Ads