36,051 Topics
![]() | |
i have an assignment a bout TicTacToe game i need its code in java language its functions are draw_board play_turn set_square check_end check_line please i need it now | |
hi, I need to use JMock to perform the unit testing of the application. The main purpose is to apply JMock in my unit testing. For that I need to create mock objects. Let me know if you have any suggestions with respect to the error:"expected method was not invoked … | |
I have my code and it compiles, and makes sense to me, but I must have something wrong because it only puts out 0's on everything except 1. There is something I am missing, and I don't see it yet. [CODE]import java.util.Scanner; public class MyBestFreon { static int max; static … | |
I just have to increment values from 0 to 23 using <c:foreach> tag in select box. This is the code snippet <html:select property="schStartTimeHH" styleClass="tableDataTextStyle1"> <c:forEach var="i" begin="0" end="23"> <html:option value ="<c:out value="${i}"/>"><c:out value="${i}"/></html:option> </c:forEach> </html:select> the value of the option tag is hitting an error. Can any one suggest the … | |
Hi I have created a simple struts application for which I am supposed to handle multiple sessions. The application works very well. But the problem is, the session attributes get swapped when multiple users access it. For example, UserA logs in, username of UserB is shown on Header. UserB wants … | |
trying to make a program(game) for two players. the game has an interface and three text fields "player1","player2", and "winning amount". the interface also has a button called rand which when pressed generates random numbers from 1 to 10 and assigns them to a particular field. assuming that the first … | |
Is there a way to tack a variable onto the end of a print.drawString so it would show up like Text: <variable> Or: [CODE]page.drawString ("Text: " object1, x, y);[/CODE] Where object1 is the variable. I tried doing that, but i get an error ")" Expected on that line, i suspect … | |
Hi people. I'm doing a project at school where i have to teach myself JAVA Netbeans. I depend on the internet for solutions. I've realised that this community really helped me alot. my project is due this friday and i'm a bit stuck, but i know i will get help. | |
I need to add a message to a picture and i have no clue of whats wrong with my code. i will post my code public class Lab6bthoma21 { public static void SimplePicture (String[] args) { System.out.println("Begin Java Execution"); System.out.println(""); //Java Program //Prompt user for a picture and open that … | |
In a programming class I have to answer some questions about various languages. One of the questions is What are the primary abstractions supported by the Java language? While I understand what an abstract is, I am not sure how to answer this question. The answer is supposed to be … | |
Hi all, I wondering how to get started with this. I am working on a method that will take two ints. These ints represent positions in an arraylist of characters. I am trying to determine if the elements of the two positions are equal. If, so display the elements, if … | |
Hi, Would anyone help me out the problem with layout components in java. I have 3 tabs, and first tab1 I have setted up with panel 1, tap2 with panel 2, but I couldn't set up component for panel 2 such as: Active panel problem display number display textarea textarea … | |
Ok so i am trying to redo my inventory program but the problem is that it won't run because i don't have a main method. Every time i try to put a main method in I get an error. Is there something wrong with my code thats keeping me from … | |
I am getting an error that says "The type Chapter165 must implement the inherited abstract method ActionListener.actionPerformed(Action Event). Can someone help me with where I went wrong? [CODE] import java.awt.*; import java.awt.event.*; import javax.swing.*; class Chapter165 extends JFrame implements ActionListener { private JTextField inputMile = new JTextField(10); private JTextField outputKm … | |
I have to create my own FTP Client in Java. Can anybody help me in the following. Which and all libraries or packages should I use. Which and all documents/tutorials I have to read Thanks in advance. ![]() | |
i want the code for avl trees using dictionaries in java... with total insert , delete, display options | |
hello smile.gif i am having trouble with the 2D array i am making.......it is supposed to be an address book of sorts Miller, Joseph, 910 Auburn Avenue, McLean, VA, 7035551234 Frank, Michael, 1 York Road, Baltimore, MD, 4105551234 Roland, Frank, 346 Bellona Avenue, Lutherville, MD, 4435551234 Smith, Jan, 432 Burke … | |
I'm writing a collision algorithm based on the Separating Axis Theorem that works like so for each side: - Gets the separating axis of the side - Measures the object's width on that axis and places the width on the axis. - Measures/places width for object that is being collision-tested. … | |
Web Server: Sun Java System Web Server 7 update 5 I have inherited a JSP application and am trying to get it to work. I have figured out that it has something to do with the [ICODE]<input type="file"> [/ICODE]tag, because I cut all the rest of the code out. [CODE]<input … | |
Seriously, what is any programming language without a HelloWorld app? | |
So I have a lot of code so I guess I'll just post the couple classes that seem to be giving me problems and where the problem is occuring. [CODE=java]// line class to store lines from .ps file class line { // for outcodes private int RIGHT = 2; private … | |
Hi , I have problem related to ArrayList...... ArrayList object may contain 1 or more ArrayList Objects and those inner ArrayList Object may contain 1 or more ArrayList Object and it is extendable to n levels. Condition is also added as ArrayList may contain different type of Objects too, i.e. … | |
guys...can post a number guessing game code so I can compare it to mine....im still have a little problem with mine.... plsssss and thnx... | |
I got the first part correct but how do I put the get height into the second part? Like would I just repeat everything the base did.. like "private double height" " public void setHeight " etc... [B]The design is this: [/B] RightTriangle variables: base, height methods: setBase - changes … | |
Hi Friends, I am having problem with the above code snippet. Initially it woked fine. But now it is giving an error of java.sql.SQLException: ORA-01722: invalid number. How can I resolve the exception? Thanks. [code=JSP] try { String ein=(String)session.getAttribute("EIN"); System.out.println("inside try block"); Class.forName("oracle.jdbc.driver.OracleDriver"); con=DriverManager.getConnection("jdbc:oracle:thin:@10.9.16.2:1521:TESTDB","HE","HE123"); Statement st=con.createStatement(); ResultSet rs=st.executeQuery("select distinct REV_OWNER … | |
BMI= w/(h/100)2 [CODE]double BMI = weight/(height*height)// Works when weight=kilograms, height= meters [/CODE] I need the output to be in kilograms and centimeters. Any help, much appreciated. | |
i want the code for avl trees using dictionaries in java... with total insert , delete, display options | |
jdbcTemplate.execute("{call TEST_CURSOR.TEST_PROC(?)}", new CallableStatementCallback() { public Object doInCallableStatement(java.sql.CallableStatement cs) throws SQLException, DataAccessException { cs.registerOutParameter(1, OracleTypes.CURSOR);//if the first variable is out parameter //here u have to set the OracleType to the variable which u r setting in the procedure cs.setString(2, "second parameter"); cs.setString(3, "third parameter"); cs.setString(4, "fourth parameter"); cs.execute(); cs.getBoolean(1); //here … | |
It keeps highlighting the line "super(r);" I can't find whats wrong with it.... The Error says: 1 error found: [B]File: C:\Documents and Settings\HP_Administrator\My Documents\Anna - java\Disk.java [line: 14] Error: C:\Documents and Settings\HP_Administrator\My Documents\Anna - java\Disk.java:14: cannot find symbol symbol : constructor Circle(double) location: class Circle[/B] The contructor code is: [code]/** … | |
I am developing a Remote Desktop kinda application. The program is supposed to get the screenshots of the remote machine along with the cursor icon image. Now my question is without using JNI is it possible to extract the mouse pointer icon (whatever it is in the remote machine at … | |
I copied this code from the textbook, so the code should have no mistake? I typed the contructor file(I think thats what its called) and the actual codes. So the code looks like this: [code]public class TestCircle { public static void main(String[] args) { Circle spot = new Circle(); spot.setRadius(5); … | |
With the release of [url=http://esd.ingres.com/] Ingres Database 9.3[/url] today, the company says it's now easier for developers to migrate their application to the open source system from MySQL, Oracle,SQL Server and Sybase. It does so, the company said, through "improved accessibility of table procedures from within the query" and support … | |
well....my teacher ask me to create a program that reads set of integer's and then finds and prints the sum of the even and odd integers....could someone help me in dis program... and can u make it simple plss....ill be happy if u would... plsss and thank you...:icon_confused: | |
Can i get java code to convert the image into binary bits. | |
Can I get the java code for online transaction to embed it with the webpages | |
Here i draw the board for chess and put all pieces in there places on the board ... then i want when i pressed by mouse on the board give me the value of x , y . I tried with all things but i cann't solve this problem please … | |
[ATTACH]11999[/ATTACH] How can I add above type text into a JTextfield??????? I mean the faded texts as "username".. It should be ok to erase them when entering text into the field.. How can I do it?? thankx in advance. | |
Hello. I'm trying to convert Calendar to dd/MM/yyyy format. My problem was it couldn't convert to exactly what i wanted. I'm Turkish so when we write a date, we write the day first then month then year... My code is here [code] public static String toFormattedDateString(Calendar input){ String year = … | |
Help me ,,... i nid to learn all about looping in java programming and what are the sample codes. plss. help me.. tnx.. | |
Can anyone please tell me how to turn on Java script,I have lost the ability to veiw photos or videos on my laptop Dell inspiron 630m. When I try to veiw anything it says that I need to download Flash player or I have to turn on Java script. | |
I want to know that can I run a code which extend JPanel and uses JFrame without running the x11 server on ubuntu. I read something about Headless but its not working. | |
Hi I just tried to create the login form using java,jsp and servlets.The database am using here is mysql. The tool am using is eclipse galileo.The code is as follows: <index.jsp> [code=JSP]<%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%> <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta http-equiv="Content-Type" content="text/html; … | |
I need to write an application that reads three intergers and prints their average, 2- write an application that reads two floating point numbers and prints their sum, difference, and product. I am doing programming projects in Java software solutions 5th edition for school. _______________________- [URL="http://ltseo.com.au/"]SEO[/URL] | |
heyy can ny 1 help me.....m wrking on jsp using ajax......i built a small application...as m new to ajax.....i built 2 field....FNAME & Lname and when my application used to do is..when you enter ur first name.....n press the tab button...the last name shld come from data base......but its nt … | |
Hello I wrote a class Employee and a tester class TestEmployee.The problem is that I get this exception after I enter the first employee's id.I thght if I give default values to the instance field the exception shouldn't have occured; can someone help me with this please: Employee class: [code] … | |
I did one J2ME SMS based Application.overview of my project.My j2me Application reside on Sales Person Handset.Sales person can send a sms to supplier to get a product.for e.g. Sales person send sms Store and related product means Suppose Store is "Nokia" and product is model number Nokia 5610 sales … | |
import javax.servlet.Filter; import org.slf4j.Logger; import org.slf4j.LoggerFactory; Hi guys, please help me out. i m not able to import the above file what could be d reason. it says cannot resolve. | |
how do you add a key listener to a java GUI? can anyone pls show me how... or at least give an example..pls:) cause I want to add a key listener to my GUI calculator but I don't now how or where to put it and stuff...:-/ thanks... | |
The End.