32,204 Topics

Member Avatar for
Member Avatar for rowen_1

Requirements 1. the user clicks the button(Go to animation page) at page one 2. the user will be directed to page two whereby an animation is played for 5 seconds 3. after 5 seconds, the user will be directed to page three. I am trying to delay a page for …

Member Avatar for JamesCherrill
0
182
Member Avatar for Steven_9

I am currently taking java and learning how to create GUI. I am trying to create a GUI whereby 1) Upon executing the application,the user will need to key in his username and password. 2) the user will be brought to second page which displays "Welcome to Page Two!" if …

Member Avatar for Steven_9
0
2K
Member Avatar for soujanya.bhat.184

Hi Guys, How to write the contents of JList into a text file. i have a JList and i want to add the list elements to a text file. How to do this?

Member Avatar for stultuske
0
280
Member Avatar for abeer araji

1. Write a program that asks the user to enter five integers and then adds and outputs the sum of odd integers, and adds and outputs the sum of even integers. For example, if the user enters the integers 7, 4, 2, 1, and 3 then the program should output …

Member Avatar for stultuske
-1
174
Member Avatar for mgold

I love the idea of dependency injection. I started doing psuedo dependency injection on my own before I knew about DI because I was frustrated programming without it. I then discovered Guice. From a program design point of view, I like it a lot. Everything is much more decoupled and …

Member Avatar for JeffGrigg
1
292
Member Avatar for prakash2813

There is a String object called detailMessage in java.lang.Throwable class, which says the reason of any exception thrown in java code. This object is initialized through a constructor using super(string message) statement or setter or whatever from subclasses like Exception and again from its subclasses like SQLException. When SQLException is …

Member Avatar for JeffGrigg
0
191
Member Avatar for moaz.amin.37

first se these methods setForeground(Color.cyan); setBackground(Color.red); these methods are defined in Component class like this java.awt.Component and we pass parameters of an other class this is very confusable for me that we pass class members as parameters to method of a different class, i mean `setForeground(Color.cyan)` i defined in Component …

Member Avatar for stultuske
0
216
Member Avatar for quontra123
Member Avatar for gagun

I am trying to write a output for my log in file on the desktop but for somereason, it is not doing that.It says the file cant be instantiated. I have the code and console output below. Any help would be much appreciated. thanks in advance. ### direct log messages …

Member Avatar for ~s.o.s~
0
2K
Member Avatar for justinelinz.sonenclar

THis is my question and I have no idea how to do it. Write a GrowSquarePrinter program that constructs a Rectangle object square representing a square with top-left corner (100, 100) and side length 50, prints its location by calling System.out.println(square), applies the translate and grow methods, and calls System.out.println(square) …

Member Avatar for iamthwee
0
318
Member Avatar for moaz.amin.37

i am very confuse about java applets so please solve my questions my question is that when we write applet then we write only methods defination not method calling so i am confuse about this that who call the methods of applets.and second is that we call the methods of …

Member Avatar for JamesCherrill
0
259
Member Avatar for mikewyatt

Hey everyone...... Sorry I havent been around for a while... had a heart-attack and havent been here for a while. Doing much better now! I am needing research material for networking multiple computers together that allow data transfer/updating in both directions. Note this is not for databases, even though there …

Member Avatar for JamesCherrill
0
190
Member Avatar for asaidi

Hi i m trying to get selected from jradiobutton..i m using eclipse and windowbuilder for java please check my code JRadioButton btn1 = new JRadioButton("By Trading Name",true); btn1.setBounds(22, 48, 149, 23); contentPane.add(btn1); JRadioButton btn2 = new JRadioButton("By Overshop",false); btn2.setBounds(22, 75, 149, 23); contentPane.add(btn2); JRadioButton btn3 = new JRadioButton("By Address",false); btn3.setBounds(22, …

Member Avatar for JamesCherrill
0
224
Member Avatar for mehul12345

Hi, i need help creating a fuel volume calculator to estimate the gallons of fuel required to travel 5 distances so far the 5 distances in miles the user enters are stored in an array, however i need a sum to find the average of the five numbers here is …

Member Avatar for mehul12345
0
864
Member Avatar for Excizted

Hello, I hope someone is more knowledgeable in Java than me while still knowing PHP! The following Java code makes a hash from a string, and I need a PHP equivalent that makes the exact same hashes. Simply md5() does not do the trick, and I looked at some PHP …

Member Avatar for Excizted
0
1K
Member Avatar for Zsolt Szücs

I have basic experience in the topic, enough for smaller projects but I would like to improve my knowledge. I would highly appriciate any source about good practices (I have hard time to decide whether a solution belongs in the "good practice" or just in the "good enough to use" …

1
141
Member Avatar for firozkiet

I have made two method ExcelCreat() which create excel file And ExcelDownload() which download that excel file. Both work separate properly but not in same time. I made a `builder.append("<"<a href='/RestSimulator/rest/userReport/download' onclick='javascript:ExcelCreate();'>Download</a>");` problem is that when I click href(Download) then excel is not created show error 500 file not found …

Member Avatar for stultuske
0
110
Member Avatar for asaidi

Hi can you please help me on this how i can change jcombobox in my frame to jtextfield when i click on next button.. then i get the data from database in jtextfield... thx

Member Avatar for mKorbel
0
186
Member Avatar for laguardian

We're creating a program based on the Opportunity card game. On each of the player's turn to draw, they have a 10% chance of drawing two cards instead of one at the price of 1000. How should we implement this? Thanks

Member Avatar for JamesCherrill
0
69
Member Avatar for hwoarang69

how to create groovy client? getting an error, below. ** # start up jboss with following paremater: # ** set JAVA_OPTS= -Djava.rmi.server.hostname=localhost -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.authenticate=true -Dcom.sun.management.jmxremote.password.file=C:\Java\jdk1.7.0\jre\lib\management\jmxremote.password -Dcom.sun.management.jmxremote.access.file=C:\Java\jdk1.7.0\jre\lib\management\jmxremote.access" ** # test jboss is started: # ** http://localhost:9990/ username: abc password: abc1# ** # Groovy script: # ** import javax.management.ObjectName import javax.management.remote.JMXConnectorFactory as …

Member Avatar for hwoarang69
0
512
Member Avatar for brittney_2

I need to write a class that stores a user-input date as a String in the format mmddyyyy. The constructor validates the input, but it accepts a String input and it tokenizes it into three parts, all int variables and in order to do that I have to tokenize the …

Member Avatar for brittney_2
0
261
Member Avatar for dami06

Hi, I have a problem with a code i have done but i just a problem..If u look at what i have attached and try to run it..It gave me a problem as i am meant to have a menu which is meant to show something inside it but the …

Member Avatar for stultuske
0
173
Member Avatar for moaz.amin.37

hello every body. I need a book at java swing package.i am new in java programming and i want to learn GUI so plz help me. i want to download book of herbert schildt. book name swing a beginner guide Author Herbert Schildt

Member Avatar for stultuske
0
347
Member Avatar for kishor.m.n

Hi all, I was just trying to write a simple prog in which i'm trying to add multiple components to a JPanel and inturn i'm adding that to a JScrollpane. Now the problem i'm facing is when i run the prog i can see the contents of the panel(not all) …

Member Avatar for mKorbel
0
10K
Member Avatar for holo12

I have array of objects how to iterate throw this array and delete some objects depending on the condition: ArrayList<Book>b=new ArrayList<Book>(); for(int i = 0 ; i < b.size ; i ++){ //if some condition //remove b.get(i); } what should I do??

Member Avatar for holo12
0
116
Member Avatar for TERRIOUS
Member Avatar for iConqueror

Here is a piece of C++ code that seems very peculiar. For some strange reason, sorting the data miraculously makes the code almost six times faster: #include <algorithm> #include <ctime> #include <iostream> int main() { // Generate data const unsigned arraySize = 32768; int data[arraySize]; for (unsigned c = 0; …

Member Avatar for ~s.o.s~
1
370
Member Avatar for Enise

Hi, I want to do full text search in mongoDB by using gridFS, but I couldn't success even though dealing with this problem too much. Can you help me please, thanx in advance.

Member Avatar for JamesCherrill
0
68
Member Avatar for Th35h4d0wF0x

I want to change two variables at once like when i set one to a value the other one is set to the same value . i used to do it with pointers in c++ but there are no pointers in java so i don't know how to do it …

Member Avatar for JamesCherrill
0
84
Member Avatar for Mr.M

Hi Dw I'm making a pos app and I would like to know if the jpos can control the device which is controlled by xfs written software. The xfs has commands in this format: AFD000 CDMOpenSafeDoor which is for opening the safe door when dispensing or should I also convert …

Member Avatar for Mr.M
0
148

The End.