Skip to main content

All Questions

Tagged with
0 votes
1 answer
374 views

JPanel inside JFrame doesn't show content sometimes. Why?

I managed to fix it but I don't understand why the same code results in different results. Some classmates have had the same problem. The issue is that it I use miVentana.setVisible(true); before ...
Juan Antonio Rodríguez Gabriel's user avatar
0 votes
1 answer
46 views

Calling JFrame from separate class

I am using Intellij IDEA 2017. I am learning how to use JFrames, and am trying to create a basic GUI. I am trying to create two JFrames in separate classes, and call them from the Main class. What I ...
Kirkland Burrill's user avatar
0 votes
3 answers
41 views

Jframe suddently not visible anymore

I was building a musicplayer. Everything worked out perfect. But when I tried to add a JList to my second JPanel it all failed.. The file compiles and does run the program in command prompt.. I think.....
Natalie's user avatar
  • 43
0 votes
1 answer
47 views

JFrame error actionperformed

I want to set the visibility of frame 2 to false, but whenever I do that, I get an error. I read something about this and it said that I needed to make my method I private method, but I can't do that ...
Raymond Timmermans's user avatar
1 vote
1 answer
336 views

JPanel isn't visible in JFrame

I Know these kind of question have been asked but i couldn't find any solution to my problem. I'm trying to paint some animation in my JPanel, which will be in a JFrame. The JPanel isn't visible, the ...
YosefBro's user avatar
  • 644
0 votes
1 answer
72 views

JTextFields don't show up, but they're still there. (the first one is "bugily" visible)

It worked an hour ago, but I must have done something to the code and I have no idea what. My JTextFields don't show up, but if I set them to editable, they're still there. The first JTextField does ...
Adrian Hansson's user avatar
1 vote
1 answer
19 views

get onVisibilityChangeActionListener

How can I call some method after frame visibility changed to true? frame.setVisible(true); My application has 2 frames. if I open second frame main frame hided. After closing second frame main frame ...
waldemar's user avatar
  • 685
0 votes
4 answers
1k views

JFrame and visibility: issue with fading out and getting a screenshot

In an action (i.e. a method) executed by pressing a button deployed into a JFrame, I want to hide the java app and then to get a screenshot. Finally, once the screenshot is taken, I need to make the ...
mat_boy's user avatar
  • 13.4k
1 vote
1 answer
968 views

The Contents Of JFrame Are Not Shown

I am using the frame for Showing messages but contents of the frame are not displayed. Below is the code for my MessageBox frame. public class MessageBox extends javax.swing.JFrame { /** * ...
Syed Muhammad Mubashir's user avatar
0 votes
3 answers
3k views

Prevent Multiple Instances of Java Frame

The application that I am working on involves frames that are created from a JPanel based upon what the user selects. I am trying to prevent a user from launching multiple instances of the same frame ...
THE DOCTOR's user avatar
  • 4,497
0 votes
1 answer
6k views

How to set the previous jframe visible when current jframe is disposed

I am making a Java gui project and it consists of two frames. The problem is that when I call the secondframe from the firstframe, I have set it such that the firstframe visibility is set to false. ...
chettyharish's user avatar
  • 1,724
3 votes
2 answers
3k views

Bringing borderless swing window to front

I have a swing program which creates a fullscreen borderless window -- I am running on Windows 7. I need the program to be able to focus and bring itself to the front. However, when I attempt to use ...
noachr's user avatar
  • 91
0 votes
3 answers
182 views

How to change visibility of ALL items in a JFrame at once?

I wonder whether there is a possiblity to change the visibility of more than one item (textbox, button, chart ...) in a JFrame in one simple(?) command. Thanks for answers and ideas! (Hiding the ...
malte's user avatar
  • 1,181
3 votes
3 answers
6k views

Why are my panels not showing up in the JFrame

public class InputPanel extends JPanel{ public static int shapeType; //1: Rectangle; 2: Oval; 3: Line public static boolean isFilled; //whether or not the shape is filled public static ...
user1787458's user avatar
0 votes
0 answers
455 views

Why a JFrame would not show in a netbeans application context?

I'm developing an application over the Netbeans API and I need to show a JFrame object. I have already designed this frame in an independent Swing application and it seems to work fine but when I want ...
nathan's user avatar
  • 1,119

15 30 50 per page