32,204 Topics
| |
i wrote this code to reverce a word but its give me a error donno why:S i hope u can help me :) [CODE]import javax.swing.JOptionPane; public class sentence { private static void reverse (Sentence){ String sentence; sentence s = new sentence(); sentence=("hello"); } /** * @param args */ public static … | |
Hello, I have a method that is returning a value of DD/MM/YYYY However, if the day if 5 or month is 7, it must have a 0 before it. So it would be, 05/07/YYYY, mine is 5/7/YYYY which isnt what I am looking for. Any help? | |
Servlet tag and servlet mapping tag are present in the web.xml as shown below [CODE] <servlet> <servlet-name>AbcServlet</servlet-name> <servlet-class>edu.studies.service.AbcServlet</servlet-class> <load-on-startup>0</load-on-startup> </servlet> <servlet-mapping> <servlet-name>AbcServlet</servlet-name> <url-pattern>/abc/*</url-pattern> </servlet-mapping> [/CODE] But it still says The requested resource (Servlet AbcServlet is not available) is not available. What did I miss? Please help. | |
Again I have been given an assignment and have done it completely wrong. Please understand that I am completely new to programing and made the mistake of entering an accelerated class. I'm not looking for an A, I just want to pass and seek out help as often as I … | |
Develop an application with object oriented model for an e-ticketing system for a cinema. It should allow its customers to browse and book tickets for movies. The system should handle customer registration , ticket processing and payment and support maintenance of the system as adding , deleting and updating movie … | |
Hi, I made two classes in Bluej, in the first class I have constructed a window and the other class is a form where data can be inputted. How can I put the form in the window and make the window visible. Is this possible or do I have to … | |
Hi! My question is how could I add the checkbox column to my table. Well, I've tried the following solution, however it provides error message (null), if the table field is empty: [CODE] tableModel = new QueryTableModel(); tableAttributesFormTypes = new JTable(); tableAttributesFormTypes.setModel(tableModel); tableModel.setQuery("select at_code, at_title, at_type from Attributes"); class QueryTableModel … | |
I am using JFrame for my GUI and I want to be able to select a row of text of a bunch of rows of text, one at a time. Like in Microsoft Outlook, you select an email and it selects the whole line for you of all the different … | |
It shows null pointer exception in Driver class, can anybody find me the error ?? [CODE]public class Node { int iData; double dData; Node leftChild; Node rightChild; public void displayNode(){ System.out.println(dData); } }[/CODE] [CODE]public class Tree { private Node root; //the root of the tree public Node find(int key) // … | |
hello, i have tow JApplet form (NewApplet1,NewApplet2) , i want to how NewApplet2 when i press button on NewApplet1. so is there any solution ? i am using NetBeans IDE thanks | |
I'm an intermediate c++ programmer beginning to learn java and curious about what people would reccomend on how to approach network programming with java. I have no desire to build webpages for browsers but to build a communications between systems to exchange data for games or other programs I might … | |
Hey guys, i'm fairly new here. Just stuck on a program. It seems like it should be right, based on my pseudo code, but something went wrong. Edit: without using Math.pow; Edit: kind of not looking for the answer, just what i did wrong,, other wise, i wont know it … | |
I'm working on an a grading program that will require the use of a couple classes. The program contains a list of "program assignments" which there are 5, and 3 test scores. The Driver class contains the scores for the students. I'm stuck writing the average methods :$ Along with … | |
[CODE] public class Node { int iData; double dData; Node leftChild; Node rightChild; public void displayNode(){ System.out.println(dData); } } [/CODE] [CODE]public class Tree { private Node root; //the root of the tree public Node find(int key) // find node with given key { // (assumes non-empty tree) Node current = … | |
I have just started taking Java as a course in college and I am having a problem understanding how to find the syntax errors in a definition for a class.I am not asking for answers I just need help understanding it more. The class is public class AA { private … | |
Please help me this question is givin me so much stress. This program is for you to get familiar with file IOs in Java as well as writing methods. Write a program that asks the user for a file name that contains a line delimited records of student applications. Each … | |
| Hi, Does anyone know where I can read about ways to protect a website from potential threats? i.e. SQL Injection, etc. In particular, a website using HTML/JSP/Servlets/Java/Tomcat. Thanks, Ashton. |
[COLOR="Red"]hey,i'm having trouble with this code...it keeps saying there is an error..can you help me please...thank you in advance[/COLOR] cannot find symbol symbol: constructor CompteBancaire() location: class javaapplication18.compteBancaire this is the class: [CODE] package javaapplication18; import javax.swing.*; import java.util.Scanner; public class CompteBancaire { private String nom,prenom,typecompte,currency; private int numerocompte; private … | |
pls,i need help in inserting a date from a text field using java, to mssql database. i am getting incorrect date for example when i insert 13/3/2010,i am getting the date 1/3/2011.i want a solution,i've searched a lot but useless. the code is: [CODE] try{ java.util.Date d; String s; d … | |
I write some coding i want to get 2 output like Example (1) of object Employee:  Id#  Name :  Age:  Sex:  etc. Example (2) of object Employee:  Id#  Name :  Age:  Sex:  etc. i just dont want a long code.. … | |
It might be quite newbie question but i've been through my books and searched online; yet still didn't find any answers. I have a couple of classes with methods in them. In my main : [CODE] public class main { public static void main(String fileslist[]) { new Folder(); Search SearchFiles … | |
If I already have a JListBox set up, but the text is too small, how do I make the font of the elements larger? | |
how to call array in main class from its derived class with its object | |
I have this method to see whether not the year is a leap year or not. heres the code i get the error missing return statement at the end. What can i do , i can't add return true or return false, becuase that screws it up. public boolean isLeapYear() … | |
i have been in a java course it´s kinda expensive but anyways i am thinking that im going to quit cause its not hard but its really overwhelming dont you get that feeling?, theres just to much to learn!, i cant believe people learned more than 1 programming language also … | |
[CODE]import java.awt.*; import java.awt.event.*; import java.awt.image.*; import java.io.*; import java.sql.*; class MyCanvas extends Canvas { Image img; public MyCanvas(Image img) { this.img = img; } public void paint (Graphics g) { if (img != null) { g.drawImage(img, 0, 0, 1000, 1000, this); } } public void setImage (Image img) { … | |
hi... can anybody tell me how to see the codes behind a java game on a web page?? thanks.. | |
hi everyone this is my code. [CODE] public class Qustion3B{ public static void main (String args[]){ double sinx = Math.sin(0.5236); double cosx = Math.cos(0.5236); sinx = Math.pow(0.5236,2); cosx = Math.pow(0.5236,2); double sum=sinx+cosx; System.out.println("sine: " + sinx+"cosine: " + cosx +"sum: " + sum ); } }[/CODE] it continue to show … | |
Ok for my uni project im wondering if its possible to make a simple game where by the user must click a button ten times to win. the button has to move after every click to a random point on the screen. Does anyone know if there are any tutorials … |
The End.