Win a copy of Java by Comparison (eBook) this week in the Java in General forum!

Bhakta Pradhan

Greenhorn
+ Follow
since Nov 26, 2010
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Bhakta Pradhan

Thans Rob I was able to load the images.
5 years ago
Hi,
Ya its similar to the last thread.In last thread I was asking about loading images archived in jar file. As per the suggestion I tried the same in simple program without making jar.But it didn't help. So I thought of starting a new thread to resolve first stage of the whole issue.

Please let me know if there is something to be changed in my program.
5 years ago
Hi I moved the images folder into src (PFA).Still images are not getting loaded :-(
5 years ago
Hi,
Please find the below code.Please let me know what changes shall I make to load the images.PFA below the project structure.
5 years ago
Hi I modified my code still images are not getting loaded.


it's not able to find the image .I have also tried only image name getResource("deploy.png")
5 years ago
Paul,
Thank for your Reply. I was able to launch a sample application through JWS. I just kept the third pary jars in the same location where I had put my application jar. And I added the jars in<resources> of jnlp file. It worked.
5 years ago
Hi Paul,
Thanks for looking into my issue.Actually I couldn't find ClassLoader.getResource() but I found ClassLoader.getSystemResource(). Hence I used the later. Please suggest me what shall I do?
5 years ago
Hi Rob,
Thanks for your response. I changed the code as below.But My program is getting terminated without any error or warning message. Using println statement I found that it's getting terminated once it's trying to execute ClassLoader.getSyatemResource() Please let me know if I'm doing something wrong?

where iconPath is string(image file name eg. "Monitoring.png")

NB:- above code is present inside static method
5 years ago
Hi,
I have used icons for buttons in my applications.Below code is able to load images when it is run from IDE(eclipse). But when I package everything in a jar file the images are not getting loaded.
Find the attachment to view the jar contents. Can you please let me know what should I do to load those images packaged inside jar file?
I'm using the below code.

where createMenuButton is a static method

where loadFile method is

where image path is defined as
5 years ago
Hi,
I have developed a swing application and now I have to package it in a jar file so that it'll be used in Java web start using jnlp to launch the UI at client side. However I have used some third party jars.

1.Can anybody let me know the proper way to package them all?

2.Can I package third party jars inside my application jar file?If yes where should I keep them in the jar file so that there won't be any class path issues while launching UI at client side?

3.Do I need to download all the jars(application jar and third party jars) separately?If yes what's the technique to put the third party jars in class path at client side?
What should I mention in JNLP file to download multiple jars(third party jars)?
5 years ago
Hi All,

I solved this , actually I was not updating the timer label inside run method of PanelTop.java


Hi Campbell,

Thanks for spending some time to look into this problem.

Actually the Stopwatch code goes below ,I don't think it could be a problem in this scenario. What you say???


6 years ago
Hi,
I just started learning Swing.I'm trying to write a program in which there will be 2 panels.Panel1->for stopwatch Panel2->which will be displaying some data and it contains a button.

My concern is I'm using Threading to update the timer of stopwatch every second. After putting print statement i can see the stop watch part is running fine but the stopwatch panel is not getting updated every second.

Below is the some portion of my code relevant to this problem.

Can anybody help me out plzzzzzzzz!!!

PanelTop is the Class for stopwatch panel

Please let me know if my approach should be something else so as to achieve the requirement
Thanks in advance
6 years ago
Hi Ulf,
For zooming I'm just left clicking on the chart and dragging.In the below link the given code is similar to what we have used in our project.
http://www.java2s.com/Code/Java/Chart/JFreeChartXYLogAxesDemo.htm
Kindly let me know if anyone have any idea ........
Hi Darryl,
I posted across many forums because I needed urgent help so that I could get some immediate response . I'm not a regular blogger so I'm very sorry if it's not in the policy of posting the same query across many forums.
Hi I'm using JFreeChart for creating logarithmic charts in my program.But when I'm zooming in some portion of the chart ,the tick mark level(numbers on Y axis) on Y Axis(which is of type LogarithmicAxis )disappears. For example when I'm zooming the portion between 10^2 and 10^3 ,I'm expecting this middle portion(On Y Axis) to be further subdivided logarithmically with new set of levels on Y axis. Is it possible to achieve using JFreeChart API if yes how can I implement this?