Let Me share this before closing this thread
http://www.japura.org/collapsiblepanel.html
Final Solution without work :)
peter_budo commented: Nice, thanx for sharing +16
mKorbel commented: note wrap that into invokeLater +9
Let Me share this before closing this thread
http://www.japura.org/collapsiblepanel.html
Final Solution without work :)
I am using Jbutton to display panel instead of Graphics class to design some thing? Will it be a good method.... I mean effeciency.....
Static keyword is visible to all instance so its updated from 0 to 2, while when u dont use static then "i" original value get printed, which is new for each instance.
Yup, drop down side menu, same in like websites... or incase if u used outlook 2007...
Please check this one...
is there any open source project for custom menu for java desktop app?
Seems like firewall issue, please open port on which you want to communicate.
http://www.java2s.com/Tutorial/Java/0240__Swing/CreatingaJTable.htm
You are missing table model. Also ur one must work.
Well problem solved without splash screen...............
I HAVE TRYING SPLASH SCREEN IN MY APP, BUT CANT GET THE BASICS YET.. SPLSAH SCREEN ISNT WORKING, CAN ANYONE GIVE ME A SIMPLE EXAMPLE
hERE is my code.
import java.awt.Graphics;
import java.awt.Image;
import java.awt.Toolkit;
import javax.swing.JWindow;
public class introduction extends JWindow {
private Image img;
introduction()
{
setSize(128,128);
img = Toolkit.getDefaultToolkit().getImage("images//loader.gif");
setLocation(Toolkit.getDefaultToolkit().getScreenSize().width/3,Toolkit.getDefaultToolkit().getScreenSize().height/3);
}
public void paint(Graphics g)
{
g.drawImage(img,this.getSize().width,this.getSize().height,this);
}
public void setWindowVisible(boolean value)
{
setVisible(value);
}
public void closeWindow()
{
this.dispose();
}
}
check your ArrayIndex as well, you need to minus when u press previous
397 ArrayIndex = ArrayIndex + 1; // increment the array index to get to the next value
Also you need else if statement to jump on first.
I just posted algorithem explaining the method... I have already recieved too many negative points on writing whole code, so i m only pointing the algo. :)
http://www.roseindia.net/java/beginners/TypeCasting.shtml
It isnt a question answer Forum, u can search easy question like this over google. Still check above link.
If you have limited user and they wont change then use hard code
switch(username)
{
case user1: checkpassword(username);
case user2: checkpassword(username);
default: User Doesnt exit;
}
checkpassword(username); //User Function for checking password
boolean checkpassword(username)
{
if password matches according to username then
true
else
false
}
If you want to use oracle or ms access for storing password then u must have concept of databases
You can also use binary file to store all username and password and fetch then from file and use them.
File and database will provide password change facility and adding and removing user facility. For large number of user database is preferable , while for small binary file is Ok.
Yes, u require a user table in database to handle this thing. Try Oracle or access according to your requirement. Or make ur own file which store username and password and encrypt it.
Same problem was with me too... So i simply made a jar with libraries and put images in a seprate folder and made a extract.
http://letshare.it/blog/saving-file-to-computer.html Cross Posted.
I think you are choosing a directory.
@NormR1, Is there any utility which can change the class file in jar during runtime? Can u please post the link
@mKorbel sorry i didnt get your second line.
int has its limit, it cant go beyond that. So loop terminate. Try long or double it will even grab more time then int.
Infinite Loop then... 10>1 after first pass it will be 11>1 and then so on....
Zero Time. Check ur condition its a straight forward maths question.
1 cant be greater then 1, which causes loop condition false and it ends before it starts.
As java programmer know that program made under java are converted to jar file for usage... And an updation in any class require that jar to be updated. So is there any way that we can update the class file at runtime rather then whole jar file. I want to provide update facility to user.
JOptionPane.showMessageDialog(null,"Yahoo\nHotmail\nGmail");
:) , Also urs one is correct.
tmodel.removeRowSelectionInterval(0,3); // Seems Wrong
Because row selection can be more then total rows.
Same for Add Rows.
line 6
SequenceFilesFromDirectory
Last Error belongs to it, U have to make object first.
What do u want to ask, referential integrity isnt any matter with java....Sql Classes in java load data according to query and you can show them in any table as you want.
// Use this constructor
FileWriter("PATH",boolean append)
i mean to enable append use
FileWriter("PATH",true);
jasper report can be used with Java desktop application....
Follow this link
http://stackoverflow.com/questions/2596641/simulate-backspace-key-with-java-awt-robot
robot.keyPress(KeyEvent.VK_SHIFT);
robot.keyPress(KeyEvent.VK_BACK_SPACE);
robot.keyRelease(KeyEvent.VK_BACK_SPACE);
robot.keyRelease(KeyEvent.VK_SHIFT);
Try Birt Report or Jasper Report. U can also use oracle reports and crystal reports, Unless u want to create your own reporting software.
Sorry its title bar.... I am trying different codes , some are working but really slow. I will post the code which suit best for this situation, if i get it before professionals... :)
how to move a jframe which has no taskbar?
frame.addmousemotionlistener(this);
public void mousedragged(MouseEvent e)
{
// What to write here
}
I tried setBounds of jframe but it flicker when we try to move the frame.
Explain a bit more
Toolkit.getDefaultToolkit().getImage(path)
An abstract class is a class that is declared abstract—it may or may not include abstract methods. Abstract classes cannot be instantiated, but they can be subclassed.
http://download.oracle.com/javase/tutorial/java/IandI/abstract.html
After a normal choice loop will bring you back to again selecting new choice state, so press 'X' to exit.
Thank you all, i will try flash later, because of my little knowledge how to use the flash api correctly..... until then gif is more appropriate
Thanx Cherrill, its also a great solution but i want to make flash attach with java.... Animation made under flash are more realistic look then gif files. VB.NET provide support for this, so i m wondering for same in java.
My main aim is to provide a startup animation , so application before start produce a good effect on the user, like word, excel etc...
I already tried google. I only saw JFLASHPLAYER Api which is not free, so i thought to use Java Fx.... So still in trouble, need professionals help like NormR1
How to add flash objects in java without Java Flash Player Api? Any idea. Just hint required.
Found the person who was using my ID...... Thanx it solved.
yes indeed its easy to create such things in java. You can also use vb.net and vc#.net.
Search the basics from the internet and try posting code.... We cant help without code nor we can make your project.
For Accomplisment check
1) JTable
2) Listener
3) JButton
4) JPanel
5) JFrame
and important of all make a diagram on paper of what you are going to create......
Yes, it is possible, google some example , i saw alot example when i was learning jtable... You can modify jtable according to your requirement.
NormR1 Right. Here is the syntax
Answer.equals("A")
Piece of cake
int a[][] = new int[2][4]; Define and SetSize
You can google many example on 2D Array. Like http://leepoint.net/notes-java/data/arrays/arrays-2D.html
http://download.oracle.com/javase/tutorial/uiswing/components/dialog.html
you dont need form , you need dialogue boxes.
there are mulitple threads , not connected with main.... when one thread ends other take its place and then other... Its a practice excerise for checking threads working from different ways.... :)