32,199 Topics
| |
Not sure how to explain what is going on but after some time scene builder just won't display the fxml file that I am trying to modify further. It happened a couple of times so far and its really annoying because nothing can be changed. Yes, I do see scene … | |
Hi, I need some help please i could not show the balls,when my pacman is moving,i want my pacman will through balls when it's moving.but i could not show his balls,can you please help me what is wrong or missing in my code. I appreciate someone can help me import … | |
Hi all Here is my snippet for(int i = 1;;i++){ System.out.println("Please enter the name:"); name = input.nextLine(); System.out.println("Please enter the email:"); email = input.nextLine(); if(!email.matches(EMAIL_PATTERN)){ System.out.println("Please enter a valid email.\nThe details are not saved please start from the beginning."); i--; // break; continue; } else { printwriter.println("|"+i+")\t|"+name+"\t|"+email+"\t|"); printwriter.println("+-----\t+-----\t+-----\t+"); } if(i>=1){ … | |
import javax.swing.JFrame; import java.awt.BorderLayout; import java.awt.GridLayout; import java.awt.FlowLayout; import javax.swing.JPanel; import javax.swing.JLabel; import javax.swing.JButton; import javax.swing.JTextField; import javax.swing.JTextArea; import java.awt.event.*; import java.awt.Color; import java.awt.Font; import javax.swing.border.Border; import javax.swing.border.TitledBorder; import javax.swing.JToolTip; import javax.swing.JTextArea; / public class Swing extends JFrame implements ActionListener import javax.swing.JFrame; import java.awt.BorderLayout; import java.awt.GridLayout; import java.awt.FlowLayout; import javax.swing.JPanel; … | |
I am following [this](http://code.makery.ch/java/javafx-2-tutorial-part1/) tutorial to get into JavaFX using scene builder and so far I really like it as the person who made it explains things in deep detail. I finished the first part and tried executing the code so far, but it returns multiple errors. Here is more … | |
Hi Team, I am beginner in Java. I am trying to prepare report using Java,the code will generate a Microsoft Word Document and add some text and images in it. I am using Apache POI for this.I am able to create and add text in the doc file and the … | |
I have just started looking into vim, and It seems very cool indeed ! However, I am not sure whether I should use it for everything or if I should use an ide with a vim plugin. I am interested in learning libgdx/android and google glass stuff. So which would … | |
I'm new in java, so I'm not very good at it yet and my teacher has stumped me. We are supposed to make a bot for a game called snacktime, which is usually user controlled. # About Snacktime: # * There are a maximum of 16 snacks layed out randomly … | |
import java.awt.BorderLayout; import java.awt.Color; import java.awt.GridLayout; import java.awt.event.ActionEvent; import java.awt.event.KeyEvent; import java.awt.event.KeyListener; import java.awt.event.MouseEvent; import java.awt.event.MouseListener; import javax.swing.*; import javax.swing.JButton; import javax.swing.JFrame; import javax.swing.JPanel; public class PanelCenter implements KeyListener,MouseListener import java.awt.BorderLayout; import java.awt.Color; import java.awt.GridLayout; import java.awt.event.ActionEvent; import java.awt.event.KeyEvent; import java.awt.event.KeyListener; import java.awt.event.MouseEvent; import java.awt.event.MouseListener; import javax.swing.*; import javax.swing.JButton; import … | |
import java.util.*; import java.io.*; public class stundentGrade { public static void main(String args [])throws IOException{ BufferedReader dataIn = new BufferedReader(new InputStreamReader(System.in)); int a=0, b=0,c=0,d=0,f=0, totalNumber=0; //declaration of initialization stars(); //method to call and print stars System.out.println("Enter a list of Exam scores from 0-100" ); System.out.println("use a negative number if you'r … | |
Hi Dw I'm trying to create a server that will handle simultaneous connections from clients and for simplicity I've decided to save data to the text files, it not one text file but there are many text files which will be located on the server. The clients (written in VB5.0) … | |
Hi there, I'm in the process of creating a utility program that builds a table in a database and inserts the initial data. I'm getting an error stating: java.sql.SQLException: No suitable Driver found for jdbc.odbc.ContactKeeperDB My Code: [CODE] import java.sql.*; import java.io.*; public class MakeDB { public static void main(String … | |
hi i need any java project on spring hibernate if any one have please send it to me | |
Hi Everyone, Thanks for viewing this thread. How do I do the code similar in Java? The syntax for the code below is C#. public class Child : Parent { public Child(String a, String b) : base(c) { } } I would like to seek for your help on Java. … | |
Hey guys, so i'm trying to learn the basics of Java, i just could not understand this code. public class Puppy{ int puppyAge; public Puppy(String name){ System.out.println("Passed Name is :" + name ); } public void setAge( int age ){ puppyAge = age; } public int getAge( ){ System.out.println("Puppy's age … | |
i want to place a button on upper left corner of JFrame with GridBagLayout.i write this code but it is notwork correctly gbc.gridx=0; gbc.gridx=0; add(b1,gbc); but the button place on center of JFrame why | |
Hello, Can anyone show me how to set width between character in java. I'm looking for something like this. Items NumOfItems Price A 2 $10 B 1 $5 When I use the for loop to make something like the table above it shows something like this. Items NumOf Items Price … | |
I noticed a few things about my results from my codes. If I don't key in anything,no matter what I press(the ok,cancel or the x button) It will print out Please enter an integer value cannot be 0 or negative and contiune to prompt me until the I key in … | |
hello to all i have problem about button events the problem is that if i handle an event of button and show again a window(result of event) that also has buttons then how to handle events of buttons of second window please help me | |
I want to play Offical Crafting Dead on my mac from my technic launcher but all I get is a white/grey screen which does not move or do anything. I would really like to play it and here is the console script... [B#439] Analytics Response [runModpack]: 200 [B#439] Java HotSpot(TM) … | |
I was looking around on the web about robotics programming, especially the Lego mindstorm EV3. I was looking at what programming languages this platform supports. I saw that you can program it in Java ME(understandable as Java is everywhere today) and in C#. I thought that C# was a windows … | |
I am getting a null pointerexception and I am not sure why. I tried debuging it by adding a system.out.print statement like so: System.out.println(GameKeys.mouse[pointer]+"-"+pointer); The output from this statment was: "null-0" # Error # Exception in thread "LWJGL Application" java.lang.NullPointerException at com.ia.df.manager.GameInputProcessor.touchDown(GameInputProcessor.java:34) at com.badlogic.gdx.backends.lwjgl.LwjglInput.processEvents(LwjglInput.java:300) at com.badlogic.gdx.backends.lwjgl.LwjglApplication.mainLoop(LwjglApplication.java:200) at com.badlogic.gdx.backends.lwjgl.LwjglApplication$1.run(LwjglApplication.java:114) ## Gamekeys … | |
I am getting a NPE on `a`. I have no idea why the array would be null, but heres the relevent code for it. public void setAbility(Ability[] abilities) { for(Ability a : abilities) { sb.append(a.getName()); } pAbility.setText(sb.toString()); } Method called here: Pokemon sPokemon = Pokemon.getPokemon(sender.getValue()); ... pController.setAbility(sPokemon.getAbility()); Passed getAbility(): public … | |
It's a code to calculate age from today's current date. I know I'll have to use #include <ctime> But I have no idea what I would use for the rest. Here's my code: package practicing; import java.util.Calendar; import java.util.Date; import java.util.Scanner; public class FindRelativeAge { private static Calendar calendar = … | |
I have acode review checklist which I would like to automate, Could anyone suggest me how i could get started with this. I would like to create a tool which takes in java extensions and reviews based on custom review check. Would this be time consuming?? any insights on how … | |
Hi Everyone. I Really Need Urgent Help To Create A Paint Application In Java Using Applets Or The Swing. Its Really Urgent. I Have Been Trying To Code This For Like Week Now And I Am Just Left With Five Days To Submit It. Thsi Application Should Be Able To … | |
Hi recently while trying to solve a core Java algorithm question I got trapped into a problem. Let me explain the puzzle. > There is a series of numbers. where difference between any consecutive > numbers is either a or b. The 1st number of the series is 0. Our … | |
I need help with my constructor that should call for all the user inputs, for example their first name, and the information gets checked to make sure it's valid. For example the name is all letters, and the identifier is actually 9 digits, etc. I can set the default constructor, … | |
hello to all..., i am working on a project and there i am facing a problem of adding pictures to a label.In my project its like that.. i have a textfield ,a button and a label. When i write the file name in the textfield and then after clicking on … |
The End.