484 byte By
dessri at 2007-9-30 15:04:03
Hello,I am trying to retrieve a field from database which is 5000 - 6000 character long using the rs.getString() method. (Data stored is XML). When the number of characters exceed 4096, the getString() returns only 4096 characters. The rest is ignored even though data is available. After ...
878 byte By
LF123 at 2007-9-30 15:03:19
Hi,I need some help in programming a section of an application I'm trying to create.I need to create a triangle (ie 3 sets co-ordinates) of images.I know that sounds simple - but I also need to be able to create two buttons and make the images rotate left or right (depending on the button ...
Can we know the type of the object created ? Is there any methodthat lets you know the type of object?For example:class Superclass{}class Subclass extends Superclass{}class TestInheritance{public static void main(String[] args){Subclass subClass = new Subclass();} }Now,Subclass is of type ...
224 byte By
chenG at 2007-9-30 15:03:06
Folks:I'd like to know if three strings are equal. I can surely do if ( (s1.equals(s2) )&& ( s2.equals(s3) ) Is there a better way? What if I have four strings?Thanks
Hi I have a string strin=1,23,4,5Can i use the indexodf and last indes\x and then a substring.To spilt the number between the comma.How do i do that.RegardsHari
1777 byte By
Saer at 2007-9-30 15:01:41
I know that it is possible to log some information without access to the source code of the classes just by running java withjava -Djava.util.logging.config.file=myLoggingConfigFilePathHowever, I can't configure that config file to log the entry parameters and/or return values. If I hard code ...
687 byte By
Arun82 at 2007-9-30 15:01:34
When i tried to pass more than 254 arguments to a function, i got a exception like this....C:\jdk1.3.1_09\bin>java Experiment1Exception in thread "main" java.lang.VerifyError: (class: Experiment1, method: main signature: ([Ljava/lang/String;)V) ...
159 byte By
willycws at 2007-9-30 15:01:16
Hi,Does anyone know how to access Oracle database Oracle 8i that is hosted on unix server via unix command line?Thanks,Willy
232 byte By
andos81 at 2007-9-30 15:01:06
how to seperate stirng ?for example :String date = "10-8-1992";how to seperate this string into three different strings.. becoming "10", "8" and "1992".can anyone please tell me how ?
i fail to make an inner class distinguish among function parameter and outer class variable.consider the following code:public class a {int var; // i want to access this one using inner class.public a(int var) {this.var = var;class b {public void fun() {var = 100;}}}}i get an error a.java:9: ...
I am trying to implement a program that parses a simple file of urls, and spits out each of there path components. This program is written in SDK 1.5 (its from a textbook), but I am trying to re-do it as an exercise for 1.4.2. I am wanting to know if I am doing this properly.Example: file ...
230 byte By
Arun82 at 2007-9-30 15:00:55
What decides the number of parameters that are passed by a function?For example in C the maximum number of arguments (and corresponding parameters) is 253 for a single function. Thankz in advanceArun :)
450 byte By
allenvpn at 2007-9-30 15:00:49
I'm trying to do some simple checks in the main method. For example:public static void main(String args[]) {// First checkif (passed1) {System.out.println("Passed 1");} // Second check if (passed2) {System.out.println("Passed 2");}}Is there a way to make sure the first check is completed ...
I am very new to Java, apologies if this is a newbie question.I want to ask the user to enter 3 numbers (console input), all at once, space delimited, and insert them into three different variables. I am wanting to know how to accomplish this with SDK 1.4.2. With SDK 1.5 you can do:Scanner scan ...
377 byte By
bregoty at 2007-9-30 15:00:24
Hi ,I need to create list of mybeans..i wanna create like this MyBean[] mb ;for (int i=0;i<5;i++){mb = new MyBean();mb.setData ("test");}for (int j=0; j<5;j++){mb.getData();}Is it possible to do like this..If so , can u give me a solution...thanks in advance,bregoty ...
2614 byte By
sgschool at 2007-9-30 15:00:11
Having difficulty debugging the following:pkg1; public interface I1 { void method1(); }pkg2:import pgk1.*;public class C2 {protected int i2 = 2;protected class C2Inner1 implements I1{ public void method1() { System.out.println("This is C2Inner1.method1."); }}}pkg3:import pgk1.*;import ...
14960 byte By
AMBUSCLUB at 2007-9-30 14:59:57
Hi I have a Jtable which populate the data from the database properly. However when i get data for a new date it still shows old data... I'm calling firetabledatachanged(). i have no clue why its doing so..I'm using Defaulttable modelHeres my codepublic class ProductionMaintenance_2 extends ...
Hello,I am trying to encrypt my database. I want to encrypt before I write and decrypte when I do a read from the database. However, if I am going to be writing to columns that are text, number, dates, etc, won't I receive errors when I attempt that?I am using prepared staments to communicate ...
564 byte By
b_bien at 2007-9-30 14:59:47
I wonder if it possible to develop an application or applet that can automate the process of signing up for courses at Notre Dame. Currently, we have to use a pretty plane text-based web system. I wonder if it's feasible to use Java to provide a more user-friendly front-end to this system. The ...
180 byte By
PeaceGod at 2007-9-30 14:59:44
when i create thread by using java language why i not see it in the prosess list on solaris by use PS command.. and how i can see how much it usage CPU
4096 byte By
pop-rage at 2007-9-30 14:59:43
this time with a dead line {tonight} :( anyway the user is supposed to enter "i am user i am user" & the program will output i2am2user2this is the code import java.awt.*;import java.awt.event.*;import javax.swing.*;import java.util.*;public class Try extends JFrame {private JLabel ...
1060 byte By
RonitT at 2007-9-30 14:59:30
Hi all,In the above interface, we have startElement method. The API says: "This event allows up to three name components for each element:the Namespace URI; the local name; and the qualified (prefixed) name. Any or all of these may be provided, depending on the values of the ...
As part of learning about Sockets and connecting, I'm trying to write an application that connects to a newsgroup server and downloads the list of newsgroups. Here's the part of the code that does the connecting and downloading.System.out.println("Processing " + hosts.elementAt(i).toString() ...
Hey all.I've got a GUI that needs to access a ssh server, and I'm using the MIndterm source code at the moment. I can't get my GUI to open up an example file (BasicClient) which is the only file I think I need to get this going. I will be modifying the file so that the terminal doenst open, ...
Hi!!!!!!!!!!!I promise u this is gonna be the last question of this topic (i hope so). How do i take ALT-ESC or ALT-TAB or ENTER or ' ? '?Bye
235 byte By
cindy85 at 2007-9-30 14:58:44
http://forum.java.sun.com/thread.jsp?forum=24&thread=544330 is really confusing me. I am trying to grasp some access concepts here but different ppl seem to be getting different results, could somebody explain?
10904 byte By
Ryltar at 2007-9-30 14:58:43
All right guys, this is an easy one... but the answer has eluded me so far. I used to have this set up with mouseListeners, but the collision checking is getting on my nerves. So I decided to attempt to change it over to keyListeners but with little success. I am not getting any input from the ...
368 byte By
viaphone at 2007-9-30 14:58:33
I have the code as following :JTextArea ta = new JTextArea ("I am viaphoe,\nHere I am , 20,30) ;JSCrollPane scr= new JScrollPane (); // I did not attatch this JScrollPane obj to the Obj ta .....How can I attatch the Obj scr to Obj ta in the following code dynamically ?thx for your reading , and ...
932 byte By
ophir_b at 2007-9-30 14:58:24
Does anyone know of an efficient alternative that doesn't... ?To my surprise, after looking at Sun's code, I discovered that after a task has been scheduled, and then its cancel() method is invoked, the reference to this task from the timer heap (queue), is not removed until the task's time ...
164 byte By
shinling at 2007-9-30 14:58:17
I'm doing a simple program to get the best selling item from a sales database. Is there any method to sort those sales by the quantity?Thanks.
I set up a simple Socket client server architecture with the Java socket API. However, my clients sometimes are initiators or requests, and sometimes my server is the initiator of infos. Example: client want to get infos from server but also want to tell the server something. The server tells ...
I populate a jtextarea with the contents of a text file. The text area has got a scrollbar. As the text has got many lines the area is set to the bottom. How can be set to the top? I mean, after populating the text areai want to see the first line of my text file not the last one. Many ...
122 byte By
HAFAZAH at 2007-9-30 14:58:00
hi i have a problem in reading SPSS file (extendsion sav) from java program, can you tell me how to read it?
185 byte By
Arun82 at 2007-9-30 14:57:59
What is the maximum number of parameters that can be passed through a function in java. Does it depend on the type of the function used?thankz in advanceArun
1606 byte By
annie613 at 2007-9-30 14:57:48
I found the function I want to use. But I am not sure how to use it.I have a class called FtoCand i return converstion of Fahrenheit to Celsius class FtoC{public static double getTemp(double tempF){ return (5.0 * (tempF - 32.0) / 9.0);}}//end class FtoCnow i want to round the converstion so i ...
897 byte By
jasongr at 2007-9-30 14:57:40
HelloI got a network connection which I obtained using:HttpURLConnection connection = (HttpURLConnection)url.openConnection();connection.setDoInput(true);connection.setDoOutput (true);connection.setUseCaches (false);connection.setRequestProperty("Content-Type", ...
Hi,I'm not able to understand the actual use of interfaces.For eg I have Class A extends b implements c,dI have 2 interfaces(c,d) which has got 4 methods and one abstract class 'b'.What if I remove the 2 interfaces c,d and write all the methods in the Abstract class 'b' so that I dont have ...
Hello,Here in my job we was using Log4J , but since some of our logs need complex things like replication forsome databases analise log t see where we will send in and lots of emails too , so we are developing our own log framework, my question is , there is a way to caught exceptions not ...
342 byte By
Reyhan12 at 2007-9-30 14:57:19
is it possible to create a program where another application can be invoked? for example, I have this java applet that has a a help button. when the user clicks on the help button, notepad opens and the help information becomes available. if this is possible, please teach me. I would like to ...
649 byte By
viaphone at 2007-9-30 14:57:15
// I have the following code : ..............................boxCon =Box.createHorizontalBox();ta1 = new JTextArea("I am hammer,\nShe is Kelly!",10,15) ;ta1.setLineWrap(true );JScrollPane scroll = new JScrollPane ...
1090 byte By
jasongr at 2007-9-30 14:57:11
HelloI have writen a progrem that sends a request to a Web site and now I need to parse the HTTP response.in the body.I am guessing that the page is encoded in UTF-8 as I can see the following tag in the resonse:<meta http-equiv="content-type" content="text/html; charset=UTF-8">Now, the ...
609 byte By
bigandyt at 2007-9-30 14:57:02
hi guys, im tryin to open a file then add changes to the end of it, at the mo im using the following but it doesnt add to the end, any ideas?try {BufferedReader br = new BufferedReader(new FileReader("H:\\new folder\\TransactionFile.txt"));BufferedWriter bw = new BufferedWriter(new ...
609 byte By
bigandyt at 2007-9-30 14:57:01
hi guys, im tryin to open a file then add changes to the end of it, at the mo im using the following but it doesnt add to the end, any ideas?try {BufferedReader br = new BufferedReader(new FileReader("H:\\new folder\\TransactionFile.txt"));BufferedWriter bw = new BufferedWriter(new ...
I have a problem like this;There's a listbox which filled up which data when the page initialized.The data source from a column containing null value in mysql datebase.I want to make a javascript function to delete the null item of the listbox.But I don't down how to detect the null item. ...
Hi All,I am trying to understand the logging API.I have used the log4J as a logging framework and hence am trying to see whether the following features are possible or not with the java.util.logging (JUL) package.1. Can i format the messages as can be done using the Log4J using pattern layout. ...
772 byte By
Heyad at 2007-9-30 14:56:37
Dear Friends,I have a problem. I know that Java passes a copy of an object or a variable to the method, so actually the original object won't be changed. I am developing a system to solve timetable problem, and when I pass an object Timetable to a method to solve it, I realize the the original ...
Hey, Good Day.Please help.Are there any existing java tools (or any open source tools but preferably Java) available out there that extracts XMP (eXtensible Metadata Platform) from any pdf file? And if there are, where can I get one? I need the source codes, and other related documentation.Any ...
getting a double number like 12.66, how to get 12 and 66 seperatly.thanks for help
1634 byte By
Adi1000 at 2007-9-30 14:56:18
Hi,I developed a way to retrieve mails using JavaMail API.In that there is a provision to download/recieve/delete mails,attachments etc.In Inbox after every mail there is a checkbox with caption as Delete,the values of which are retrieved when Delete button is clicked.Problem is that when i ...
174 byte By
omd2 at 2007-9-30 14:56:17
Hi, which would be best the way of cutting character strings without delimitors(ex : aaaaaaaabbbbbbbbccccccccdddddddd) in regular interval?Thanks.