36,051 Topics

Member Avatar for
Member Avatar for Monkeeboy

Hello, i'm justarting out with OOP with Java and i'm looking for a bit of help with a bit of code as i can't quite work out why it wont work as i'm still learning. Here's what im being asked to do [I]write a public method called requestPositionsAndMove() which takes …

Member Avatar for Monkeeboy
0
176
Member Avatar for AaronLLF
Member Avatar for Akill10
0
182
Member Avatar for mokztan

Hi. Im having a difficult time to figure out how to connect all the claass and jsp as well as the .xml. (I am working on a web application project, and these codes are for the registration module oly. Im using ECLIPSE EUROPA for my IDE, Apache Tomcat 6.0 for …

0
92
Member Avatar for aksahoo17

Hello everybody, As i m beginner to Jsp/Servlet.. I want to Upload a image from client side and store it in MySql database then simultaneously display it. I need it urgently can anybody send me the code....... Please,..... Thanks

Member Avatar for jahanruhi3@gmai
0
183
Member Avatar for bhakki

hi all, I developed j2me, android and blackberry based applications. I need to showing the demo for clients through my own website. Is this possible for showing the demo using micro emulator through my website?. For example user can choose the both type of mobile and type of application and …

0
220
Member Avatar for rusl07cl08

Write a program that asks for your age in years, months, and days and writes out your age in seconds. Do this by calculating the number of total days you have been alive, then multiply this by the number of hours per day (24), the number of minutes per hour …

Member Avatar for rusl07cl08
0
1K
Member Avatar for rakhi4110

hi, I am working a program which needs to send an email through JSP. I get an error Could not connect to host : localhost :25 : Connection refused. error. Can anyone tell me what configuration i need to change in Apache Tomcat to use my server as smtp server.. …

0
70
Member Avatar for rakhi4110

Hi everyone, I'm naive to javascript as well as JSP. I'm involved in a project where i need to code a web page similar to shopping cart type of thing. The user selection needs to be displayed in the same page dynamically using JavaScript and then after confirmation from the …

Member Avatar for rakhi4110
0
138
Member Avatar for sydneytot

Can you help me in this program java applet. this is a program that the user will input one letter in all the textbox.When you typed all the letters correctly you will click the button and will prompt accepted else invalid. The letters in every textbox is fixed: A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,,W,X,Y this …

0
54
Member Avatar for sirlink99

My game that I made works correctly when I run it in the window from my IDE, but when I run it from a browser the game buttons don't animate. can anyone tell me why it's not working? another problem. When [I]New Game[/I] is pressed in the IDE window a …

0
43
Member Avatar for Neversleepin

Hi, is it possible to get the list of last life added in a folder with java? i don't want to get the lastmodified file which return a date or time. i want to get the file name of last added in a folder. Thank you all

Member Avatar for Ezzaral
0
6K
Member Avatar for LianaN

Hi! Could someone please give me any idea on how to add a background image to JInternalFrame without subclassing. Below I provide a code snippet, but the line [ICODE]jif.setBackgroundImage(backImage);[/ICODE] is incorrect. Please, help me to fix this error. But I don't want to create a subclass, e.g. MyJInternalFrame. Thanks! [CODE] …

Member Avatar for LianaN
0
854
Member Avatar for hao90

How to let the button set to it "latest" text because i suppose to set the button's text to "booked" and the foreground to red. However, everytime i re-run the program, the button re-set. I know i should do something on constructor, but how? Here is my coding.. Thanks for …

Member Avatar for JKP()
0
94
Member Avatar for bangor_boy

Have written code for a game, a letter is randomly choosen by the programme and then the player has to pick the same one with the sequence getting longer and longer, the choosen letter is added to an arrayList for the game and then when the player picks a letter …

Member Avatar for bangor_boy
0
126
Member Avatar for bantipatel
Member Avatar for montalbano80

I am creating a Pool.java code for class final and all we need to do is to create a program that calculate the volume of the pool after the user enters the size of the pool. I have only one line where my code is giving me a error. The …

Member Avatar for Akill10
0
630
Member Avatar for purijatin

In the below code, iam calculating the time taken to calculate the Square Root of first 30000000 numbers. But there is a weird thing happening: [CODE] import java.util.*; public class Cache { public static void main(String args[]) { for(int j=0;j<=1000;j++) { ; } float[] a = new float[30000000]; long as …

Member Avatar for purijatin
0
189
Member Avatar for newbie14

Dear All, I am using an adapted code from the web for sending sms via gsm modem. Now I would like to modify to read sms message from database table and send it.So I would like to programme it to read on every 30 second from the db process and …

Member Avatar for newbie14
0
116
Member Avatar for javanoob101

I've changed some of the code but the animation plays when you keep pressing the space bar. I want it to animate my bullet across the screen just by pressing the space bar(not by pressing the space bar mulitple times). Thank for your help! *Note: the old code was posted …

Member Avatar for javanoob101
0
231
Member Avatar for sirlink99

Hello. I am having trouble with my menu and buttons (which are just pictures that change when you scroll over them). One of my buttons works perfectly, but when I coded the rest in the same way (at least I think so) they dont work. Sorry for the long code. …

Member Avatar for sirlink99
0
164
Member Avatar for ellenski

Hi, There is something wrong with my code. I can't seem to access the database anymore not can I add new data information. I am suppose to create a registration form with username and password. Then save it to a database on MS Access. Then login using the login form. …

Member Avatar for boblarson
0
142
Member Avatar for sirlink99

I imported a picture onto another picture and I am wondering how to get rid of the white around the smaller picture.

Member Avatar for sirlink99
0
272
Member Avatar for sirlink99

when the space key is pressed then the menu apears, but when you press the resume button (cont) then the menu should dissapear, but it doesn't. please help. Thanks [code]// The "ArrowKeys" class. import java.applet.*; import java.awt.*; import java.awt.event.*; public class ArrowKeys2 extends Applet implements KeyListener, Runnable, MouseListener, MouseMotionListener { …

Member Avatar for sirlink99
0
368
Member Avatar for methmignonne

hi. im doing an edge detection which will detect edges of each RGB channel and then combine them to show it as a final output. im now having a problem with combining the three as it doesnt show me a binary image, instead it has some colors on it. i …

0
203
Member Avatar for NasserSJH

hi.. I don't know why the circle doesn't move .. [CODE]import java.awt.*; import java.awt.event.*; import javax.swing.*; public class MouseGameV2 extends JFrame implements MouseMotionListener { CircleClass a[]; Graphics gx; int m = 5; Thread move1; //---------------------// JPanel p1 = new JPanel(); JPanel p2 = new JPanel(); JPanel p3 = new JPanel(); …

Member Avatar for NasserSJH
0
205
Member Avatar for riahc3

Hey This might sound like a dumb question but I simply dont know how to do it. Not only that but for some reason I do not know, my professor refuses to teach me how to use debugging and watch variables. He wants the "change, try, and test" method.... I …

Member Avatar for riahc3
0
903
Member Avatar for Java-Newbie

Can anybody tell me why I keep getting this error? [CODE]Asig02_Attempt2.java:37: <identifier> expected public void sincronizarCanal(canal)[/CODE] Am I mixing a [I]class [/I]with a [I]method[/I]? This is just a small program that simulates a TV. I'm trying to pass a number (chanel) to a method that tells the user that they …

Member Avatar for javaAddict
0
6K
Member Avatar for Amuthaalbe

I want to implement gabor filter in java. I got gabor filter code in Matlab. i tried to convert it into java but it had some mistakes. pls check the code and fix the errors. i post both the matlab code (which i got) and java code which i had …

Member Avatar for Amuthaalbe
0
545
Member Avatar for yukikazemedia

I have this code which sorts any given number to ascending order, but I'm having difficulties figuring out how to sort the numbers given into a descending order. Code: [CODE] import javax.swing.*; import java.util.Arrays; public class sort7 { public static void main(int[]array) //public static void main(String[]args) { String str1=""; String …

Member Avatar for Eric Cute
0
325
Member Avatar for Eric Cute

Hello Guys, Im having a bit of a problem here. Im trying to deploy an EJB project that i developed using Eclipse Galileo Version 3.5.2 using JBOSS 6.0.0.Final as server. When I try to deploy my test EJB its giving me an error that it cannot instantiate class [org.jboss.logging.util.OnlyOnceErrorHandler] ClassNotFoundException. …

0
95
Member Avatar for pmark019

I want to count the number of lines that are inputed in my program but I don't know how. Can someone please help me. Here's my code: [CODE]import java.util.*; import java.lang.*; import java.io.*; public class Exer6 { public static void main(String args[]) { String[] dummy1, dummy2, dummy3, dummy4, dummy5; String[] …

Member Avatar for pmark019
0
181
Member Avatar for Argyrisv

I want to compute md5 hash from a MimeMessage type.I use the following code to do this: [CODE] //MD5 private static String convertToHex(byte[] data) { StringBuilder buf = new StringBuilder(); for (int i = 0; i < data.length; i++) { int halfbyte = (data[i] >>> 4) & 0x0F; int two_halfs …

Member Avatar for Argyrisv
0
192
Member Avatar for mutago

GOODAY experts, this code was to display an image from the database but when I runs it it displays an empty page, I tried to extend using Jframe but it still display an empty page. in my EXCEPTION I tried using PRINT STACK TRACE nowhere. please help me to fix …

0
92
Member Avatar for program_vission

Is there any other way to get to next record without refreshing the current page in jsp.

Member Avatar for program_vission
0
64
Member Avatar for emcyroyale

Hello, I am making a program that tries to identify if an inputted word is a palindrome( word or number that reads backwards and forwards the same) but with the Pali() method of my program I have found out that when I compare the substring of letters it always ends …

Member Avatar for JDCyrus
0
194
Member Avatar for LianaN

Hi! I am working on scaling the image that is placed in JLabel. The scaling method itself works more or less fine, however a black border appears around the image after scaling. I tried to make the transparent/white JLabel background, but my attempts failed. Please explain me how could I …

Member Avatar for LianaN
0
450
Member Avatar for Raghu D

hi! In my project ,the url should not be shown to the user.I want to hide it using servlet filter. Can anyone help me ,how to achieve this task...........thank u......

Member Avatar for ~s.o.s~
0
2K
Member Avatar for rusl07cl08

Write a program that computes XN where X is a floating point number and N is a positive integer. The program informs the user that N must be positive if the user enters a negative value. Of course, XN = X * X * X * ... * X -------------------- …

Member Avatar for Akill10
0
670
Member Avatar for DragonL

I have a problem whit load of xml file into Oracle using StringBuffer. I get a java.sql.SQLException error “setString can only process strings of less than 32766 characters”. My problem a cure when I try to bind the CLOB with the prepared Statement in the StringBuffer. There are no problem …

Member Avatar for masijade
0
420
Member Avatar for Janu Sam

Hi, In my application, I am creating a string array in a method. Each time I call that method this array will get created and also a null pointer exception is showing when I use the Arrays.sort() method. My method is like this... [code] int count = getTotalXMLCount(); envArray = …

Member Avatar for Janu Sam
0
386
Member Avatar for jamojo

Hello Everyone, I created a java code that runs batch files. Then, I deployed the java classes in apache-tomcat-5.5.26. The code worked when I ran the tomcat manually but when I ran the tomcat as a windows service, it did not work. I checked the tomcat log files but apparently …

Member Avatar for ~s.o.s~
0
151
Member Avatar for coco24

Hello I am new to Java and I have no idea where to start with this program. Can somebody please start me off or display how you would execute the code. Thank you. This is what I have so far, but it is just the basics: [code] /* * For …

Member Avatar for JKP()
0
122
Member Avatar for anithajerome

Hi I am running an jsp application thru which the values are saved in mysql. all values are saved twice.Pls help me how to avoid that

Member Avatar for masijade
0
163
Member Avatar for ChiboSempai

I wanted to make a program that deals with the editing of hex files, but I'm not sure how I would go about doing this. Normally I can just input a file into a Java program, read it into a String, then do what I please with it. If any …

Member Avatar for JamesCherrill
0
234
Member Avatar for ubi_ct83

hi, if i have this kind of string list: String num_list="1,2,5,3,4,6"; how can i make it in array? arraynum[100]=[1 , 2 , 5 , 3 , 4 , 6]

Member Avatar for masijade
0
74
Member Avatar for ypks_destiny

I am working on Myql database and netbeans. i want to edit the table in a Jsp page and i want to place new values in it. I mean the previous data in the table must be dispalyed after that i want to edit it and replace new values ...after …

Member Avatar for ypks_destiny
0
2K
Member Avatar for Neversleepin
Member Avatar for peter_budo
0
467
Member Avatar for Chaster

Hi all! My problem is the following: I'm using Spring MVC, and trying to use several controllers (one for each jsp). My controllers are defined in the xml like: <bean id="/login.htm" class="controllers.LoginController" /> <bean id="/menu.htm" class="controllers.MenuController" /> inside LoginController's onSubmit I do a ModelAndView("menu", ...). That is OK, the menu …

0
83
Member Avatar for o0sample0o

Hello, i'm a new member here in this forum.. and i think lot of programmers may help me here.. i'm a newbie also in java programming.. my teacher wants us to make a program that accepts 5 integers and then arrange it from highest to lowest.. i have an idea …

Member Avatar for Eric Cute
0
1K
Member Avatar for sasi_88

hi i have the database like author books etc but i want to the tree lookup ->author ->books ->topics first on page load display all the authors from the databse and click the particular author display the child node of all the books written by the author. again click the …

0
60

The End.