Java/Questions

SubjectDate AskedExpert
RMI2/2/2012Artemus Harper
  Q: i received your answer its very helpful to me, and i have another doubt whether socket permission is ...
  A: You can connect to the server the jar came from without RMI. It might be possible to use RMI if the ...
Java array2/2/2012Neal Ziring
  Q: In java,arrays are dynamically allocated or static?Explain in detail.
  A: Preeti, > In java,arrays are dynamically allocated or static? Explain in detail. In Java, all ...
chat messenger in java1/31/2012Ziv Ben-Eliahu
  Q: sir, i am a student of IT engineering (2nd yr) and i have a mini project based on the creation of a ...
  A: This is a very general question so I can only provide 2 suggestions: (1) There is so much ...
RMI1/31/2012Artemus Harper
  Q: i am M.Sc(cs&it) student i have a problem to run RMI because of socket permission so please send me ...
  A: Socket permission issues generally refers to trying to communicate to another server using an ...
Form submission to j_security_check1/30/2012Neal Ziring
  Q: I came across a login form in jsp as follows, <form method="post" name="login" ...
  A: Thomas, The "j_security_check" action is a relative URL. For example, if you saw that <form> tag ...
Form submission to j_security_check1/30/2012Brian Ngure
  Q: I came across a login form in jsp as follows, <form method="post" name="login" ...
  A: The special resource "j_security_check" used in the action attribute of the form is a special ...
java applet1/29/2012Artemus Harper
  Q: we know that in javascript we enter the source code by browser +view+ source but how to view the ...
  A: Java applets are compiled code, there is no source code typically available. You could get a java ...
java applet1/29/2012Neal Ziring
  Q: we know that in java script we enter the source code by browser +view+ source but how to view the ...
  A: Dax, > > we know that in java script we enter the source code by browser +view+ source but > how ...
the getlocalPort() method1/28/2012Neal Ziring
  Q: Below, I have a code snippet of a client socket. I do not know how to get the local port of my ...
  A: Henry, > > My concern is I can't get an available port to connect to :( I tried the port 80 but it ...
using the getlocalPort() method1/27/2012Artemus Harper
  Q: Below, I have a code snippet of a client socket. I do not know how to get the local port of my ...
  A: You can get a list of commonly used ports. The vast majority of ports will not be used on a system, ...
using the getlocalPort() method1/27/2012Artemus Harper
  Q: Below, I have a code snippet of a client socket. I do not know how to get the local port of my ...
  A: You could iterate though a range of them and see what one is available. Note however that this ...
the getlocalPort() method1/27/2012Neal Ziring
  Q: Below, I have a code snippet of a client socket. I do not know how to get the local port of my ...
  A: Henry, I don't understand what your code is trying to do. I think you may be confused about the ...
using the getlocalPort() method1/27/2012Artemus Harper
  Q: Below, I have a code snippet of a client socket. I do not know how to get the local port of my ...
  A: The method getLocalPort() always has been a method in the Socket class. You really don't ever need ...
reading image files1/26/2012Artemus Harper
  Q: I'm having a small problem in reading jpeg images. for(i=0;i< streamData.length;i++) { ...
  A: Instead of just printing out that the image does not exist on any exception, you should print out ...
Threads1/23/2012Brian Ngure
  Q: I want to print the numbers form 1 to 100. Here i want to use two threads, one thread prints only ...
  A: Could you put your code up here and I can help you out. Basically, you should write the code for ...
java1/19/2012Artemus Harper
  Q: good morning sir... sir is it possible to add a url in java swing or in jlabel.....
  A: Yes you can. You can put html code in your jlabel by having the text inside the JLabel start and end ...
Question about PixelGrabber Class1/18/2012Ziv Ben-Eliahu
  Q: I am trying to solve a problem where I have two images stored in two BufferedImage objects and I ...
  A: 1. Use the other constructor in which you also provide the byte array to which the pixels will be ...
JAVA ARRAY1/15/2012Brian Ngure
  Q: good morning sir.... actually i tried to find a value from array in java... if suppose searching ...
  A: You need to edit the actionPerformed method. 1. You were creating the MySQL connection but not ...
java mysql1/14/2012Neal Ziring
  Q: Good morning Sir i m just trying to insert data into mysql using java swing... i tried some ...
  A: Murali, > > i have attached coding with error. > Yes, there is a serious error in your code. ...
java mysql1/14/2012Artemus Harper
  Q: .... i m just trying to insert data into mysql using java swing... i tried some methods from ...
  A: The satement: DriverManager.getConnection(url,username,password); needs to be Connection conn = ...
JTable Searching with highlight1/10/2012Brian Ngure
  Q: I have already searched for similar threads but with no results helping me I want to make the text ...
  A: Are you sure you want to highlight as opposed to filter out the extraneous results? If you highlight ...
JAVA ARRAY1/9/2012Anthony Levensalor
  Q: good morning sir.... actually i tried to find a value from array in java... if suppose searching ...
  A: I modified the application to find the value entered at the command line using the java.util.Arrays ...
JAVA ARRAY1/9/2012Brian Ngure
  Q: good morning sir.... actually i tried to find a value from array in java... if suppose searching ...
  A: You get a java.lang.StackOverflowError. This basically means that your program is running out of ...
JAVA ARRAY1/9/2012Artemus Harper
  Q: good morning sir.... actually i tried to find a value from array in java... if suppose searching ...
  A: You are trying to do this problem recursively. That is find calls check, which calls find again, and ...
removing blue and red channel from RGB color image1/8/2012Artemus Harper
  Q: Below is my code snippet.I need to extract red and blue channel and my resultant image should be in ...
  A: All you need to do is set the RGB value back on the image: File e = new File( "1.jpg" ); ...
What should be put in main?1/5/2012Anthony Levensalor
  Q: I would like to know what the minimum information should be put into the main. Every time I write a ...
  A: This is a great question, and you're on a good path just for knowing to ask it. The way I handle ...
java mysql1/3/2012Artemus Harper
  Q: sir how can i find/check whether a column and table present in mysql using java.... thanks sir...
  A: To determine if a table exists in a database (which is rare you would do this, as the database ...
java mysql1/2/2012Artemus Harper
  Q: good morning sir have a nice day.....happy new year... shall you explain java with my sql ...
  A: Your two programs are different, I don't understand why you would expect them not to change. I did ...
java mysql1/2/2012Artemus Harper
  Q: good morning sir have a nice day.....happy new year... shall you explain java with my sql ...
  A: Typically if you want to use variables in your sql queries you want to use a PreparedStatement, as ...
java1/2/2012Anthony Levensalor
  Q: sir my doubt is about exception handling .you please read the following two paragraphs 1)”There is a ...
  A: 1. Yes, that is correct. The second item is, in fact, a direct quote from the Oracle documentation ...
Java with Oracle12/31/2011Brian Ngure
  Q: import java.sql.*; class Kettavan { private Connection conn; private Statement stmt; ...
  A: Some things to try: 1. Check that the host name is correct in the listener.ora and tnsnames.ora ...
java & oracle12/29/2011Brian Ngure
  Q: i tried most websites methods to connect java with oracle but cant... shall u guide me from the ...
  A: Try this. Let me know if it throws an error. import java.sql.*; class Kettavan { private ...
Could not find the main class error12/27/2011Anthony Levensalor
  Q: I was creating a test program to output the square root of an input number and after working through ...
  A: Your code is fine, and your program works. It sounds like you're trying to run it like this: "java ...
java & oracle12/27/2011Brian Ngure
  Q: i tried most websites methods to connect java with oracle but cant... shall u guide me from the ...
  A: To connect to an ORACLE database, make sure you have the Oracle DB driver jar file in your path. ...
servlet12/27/2011Brian Ngure
  Q: i am starting java programming and i want to do web programming but i dont know what should i ...
  A: A servlet is a server side Java program that runs inside an application server like Tomcat or ...
Java with Oracle12/24/2011Artemus Harper
  Q: good morning sir.....how do u do..? sir from last 24 hours i tried to connect my java prog with ...
  A: The first error is related to the network, it is possible that the database wasn't running at the ...
Supermaket Simulation Using Queues12/23/2011Ziv Ben-Eliahu
  Q: I am trying to solve the Supermaket Simulation in the Java textbook (deitel and deitel) using the ...
  A: All in all, you are in the right direction. The main thing you are missing is enqueue and dequeue of ...
Even and Odd Sorting12/20/2011Ziv Ben-Eliahu
  Q: Sir i am stuck in one method where i would pass an integer array as an argument which will contain ...
  A: Let me hint in the right direction - imagin there is a person going over the array. He goes one step ...
table in java12/16/2011Artemus Harper
  Q: heyy artemus, i want to know how to make a table in java ANSWER: If you want to display a table to ...
  A: I have a difficult time understanding you. By default users can edit the table by just double ...
table in java12/15/2011Artemus Harper
  Q: heyy artemus, i want to know how to make a table in java ANSWER: If you want to display a table to ...
  A: You should look at a tutorial: http://docs.oracle.com/javase/tutorial/uiswing/components/table.html ...

Page:   1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10  |  Next      All

Java

All Answers


Answers by Expert:


Ask Experts

Volunteer


Artemus Harper

Top Expert on this page

Expertise

I have a Masters in computer science. I can answer questions on core J2SE, swing and graphics. Please no questions about JSP or J2ME.

Experience

I have experience in Core Java, good background in Java swing/gui, some experience with JNI, Java reflection. Some experience in bio-informatics. Basics in c++ and c#

Organizations
Washington State University

Education/Credentials
MS in Computer Science from Washington State University and a BS in Mathematics and Computer Science from Central Washington University.

©2012 About.com, a part of The New York Times Company. All rights reserved.