Hi ,I have a string and I should be converting it into to ASCII character.Is there a method in java where we can convert a character(something like "a") to a ASCII character("65").Thanks,Anna
I have deadline tomorrow morning. And I dont know what to do :(I should do a sorting program. do-while loop is not working right, and there issomething else wrong with run-method.May someone kind person help and save me! :)-Create a class Toolkit which contains an implementation for sorting ...
2454 byte By
wzhihaia at 2007-9-28 2:54:49
I have a servlet on our machine(linux+tomcat+jdk) . When I tested my java application in my windowsmachine it worked fine. when I pushed to our unix machine and I could compile it without a problem. BUT, when i start runningthe application I got this error:description:The server encountered an ...
I have been given an assignment, but am really struggling with it, I would be really grateful if someone could help me with it, its a very important assignment!The assignment is: -__The numbers 1, 1+2 = 3, 1+2+3 = 6, 1+2+3+4 = 10 etc. are known as triangular numbers. (Think of a set of red ...
Recently I have been coding some Java for the first time in a while, and today discovered an error I always used to make in my code. For some reason, I assumed that protected meant that a field or method was only available to the class or any of its subclasses. I now realise that I was wrong ...
I'm having some problems with the java code that i'm working on. I keep getting two errors saying "illegal start of type". I need to create an applet that interprets a simplified version of the Logo language, and displays the results on screen. Any help is appreciated!! THANKS.import ...
Hello Group,I have been trying to find answer for this question since quite a long time.The question i have is that the methods pertaining to threads like wait(), notify(), notifyAll() are exclusively used by threads themselves.Even then why are they been implemented in the Object class?Thanx ...
496 byte By
gunjanGa at 2007-9-28 3:38:41
I'm trying to access a file over http from my java program. The file is hosted on IIS server and anonymous and basic authentications are turned off. The only authentication available is "Integrated windows authentication". I'm not able to get the file using this setup. But if I allow ...
I want to declare two String arrays in first class and call them in second class constructor and just want to print them from the second class just its very simple as I am new to java any body try to help this novice,need a simple code snippetthanks in advance
Hi all!, someone knows about an API that let me use a scanner from Java?without programing JNI code.thks in advance!.
Hello all!In delphi ,there is a statment of reference of class,like "class of TSomeClass,I have some code write in delphi expediently,but in java hardly,please give some suggestion.here are my codes in obj.pas writed in delphi:....TObjClass = class of TObj;....TObj = class(TObject); //TObj is a ...
Hi,I have written a GUI program to get userid and password to connect to a Telnet session. The purpose of the program is just to check if the user is a valid user and start another application if the user is a valid user. This application works well and is installed for manay users at my work ...
Hi there,I've been searching for about two days now, trying to find a solution to our problem. We want to open MS Explorer from a link in Netscape. So basicaly force the link to open a new window in MS Explorer (this is for an internal jsp application).I think that the answer that I found in ...
Is there a way to check the monitor state of an object? For example,before entering a synchronized block I want to check if there is a monitor on the object and skip the block so the thread is not forced to wait. Thanks in advance.
I used this code to display images in an html page. One applet for one image. But out of the 8 images I loaded, 6 adjusted themselves to 320x240 automatically, 1 randomly jumps around to certain parts of the image every 250millisecs, and 1 just cuts the top left hand part of 320x240. How can ...
233 byte By
dugganaa at 2007-9-28 4:11:33
Hi,I have a thread and I started it by claling thread.start() and some where in my code i want to say thread.start(), which jvm won't allow me to do so... could u please reason me elaborately?ThanksSato.
522 byte By
m_asua at 2007-9-28 4:19:51
I am using j2sdk1.4.1In one of my methods, I have a StringBuffer object. But when I try to use method 'delete' for the StringBuffer object, I get an error saying that 'delete is not a method of class StringBuffer'.In the documentation the method is available. Following the what the ...
following the my code:the class "test.temp".........public temp() {super();}..........public static void main(String[] args) {try{TestCLASS.testCLASS("test.temp");}catch(Exception e){System.out.println(e.getMessage());}}..............public void getDETAIL(String name, String job) ...
Hi , What is the advantage of using ArrayList over Vector. As far as i know Vector is thread safe and hence inovolves lot of overload . Just curious how much time overload it will generate.?
882 byte By
m_asua at 2007-9-28 4:29:21
hi allthis is the code that I am trying to implement in my application. http://forum.java.sun.com/thread.jsp?forum=1&thread=161358(thanks to johnmpage who posted it).But I am having a problem. In my application I am not able to use delete method of classs StringBuffer. I get a compile error ...
Is there an easy way to read first word of each line of the file?These words r accomodated in double quotes.For eg:"1" "John Smith" "london" "UK""2" "Adam Holmes" "New York" "US""3" "Shane Warne" "Adelade" "Aus"and so on ...I want to read ...
948 byte By
0m4ra at 2007-9-28 4:40:08
I write a little class the transforma Unicode string into an ASCII one.it works good if i don't use char as ?, ?, ?, ?, ? and i dont'know how i can solve the problem. the code i write is this:[tt]public class Unicode2ASCII{ public static void main(String argv[]){String s = argv[0];byte b[] = ...
hi,iam designing a sample GUI which almost resembles Visual basic(IDE).ie A toolbar,A form window,A menu bar,A toolBox(component box)i just made it possible.now i want to add all the components from the tool box onto the form like VB(i shall be able to add any number of ...
150 byte By
mup079a at 2007-9-28 4:57:35
Hi everyone !I'd like to know how I can read the String written in a JLabel, without ActionEvent on it. Thanks to anyone who help me !!
1198 byte By
lafon1a at 2007-9-28 4:57:57
Hello!I'm trying to decrypt a string with DESede method. My programm contains the following elements :str="c215757e76495452"d'o?str.length()=16byte[] dec=new byte[str.length()];byte[] decFinal = new byte[str.length()];BigInteger bVar = new BigInteger(str,16);dec = bVar.toByteArray();int i = ...
Hi friends,I have one small doubt. Is importing the entire package will take more memory than imporing the individual classes?. Say for example there is one package name mypack which consists of 100 classes. I need only 10 classes in that. Is importing the entire package (import mypack.*) will ...
Hello, I am trying to find a way to access the Serial ports through Java underLinux. Currently I am able to write to the serial port by opening "/dev/ttyS0"as a file and then write data to it.Now the only problem is that I need to be able receive data over the serial cable as well. Does anymore ...
I have several files and want to pass them as arguments to a Helper class for further processing. I put the public static void main (String arg[]) {} class and the Helper class in a package.I got error messages "cannot resolve symbol" for: 1. variable XSLTransformHelper for if ...
I would appreciate any suggestions or ideas as to any additional features I could possibly implement in my program. This is part of my final year degree project.The program is intended to be an OO Documentation Tool and its main function is to convert Java source code to UML Class diagrams.The ...
710 byte By
caballoa at 2007-9-28 5:48:10
I HAVE A PROJECT TO DO AND I'M NEW TO JAVA. I HAVE TO Write a Person class that contains private member variables name, age, and gender; and six public member methods getName, setName, getAge, setAge, getGender, setGender to access the private variables.Write an AddressBook class that manages ...
Hellopresent i am implementing Audio Recording and Playingbut i want how to get the Voice pitch that is audio frequencyin java...during the Audio Wave File playing...in this case if any sample code please send them...this is very
165 byte By
lafon1a at 2007-9-28 5:50:21
Hello!How can I do a backup of a database?How can I restore it?I don't success in all my tests.thanks for your help.lafon1
Let's say I've a resource which is to be accessed bothremotely (by means of RMI) and locally (in that case all is runin one VM and no networking is performed -- no RMI at all).Suppose I have a DBConnection class which is in fact can be a local connection or a remote one (and represents this ...
75 byte By
marjowa at 2007-9-28 5:51:57
What code can i use to enable me to attach a file through my applet?
I get the following error when compiling the following code could you please help me in figuring out how to resolve the error.Exception in thread "main" java.lang.NullPointerExceptionat ColoredTextPane.init<IRCClient.java:924>at ColoredTextPane.<init><IRCClient.java:909>at ...
I'm creating a text file but when a check the file it contain some garbage... salida = new DataOutputStream (new FileOutputStream ("client.txt")); salida.writeUTF("Hello");salida.writeUTF("my");salida.writeUTF("world");but when i check the file it contain: Hello my wold i don't know why ...
I run following piece of code in solaris and windows env. and get different results. Pls can someone give idea what is wrong in my solaris setup.//CODE START--public class TestEncBasic{ public static void main(String arg[]) {String strURL = "%DC" ;String strTest = ...
214 byte By
marjowa at 2007-9-28 5:59:11
Hi! really need help. I'm creating a chat client applet. I'm working on the applet for loggin in...What code can enable the applet to accept and remember the username and password everytime a user logs in.
Hello Everyone, Any help with this respect will be greatly appreciated..We have created an application which uses Weblogic as the Application Server and the front end is written in HTML which uses HTCs. Data from the front end to the back end is sent in the form of XML. The application as such ...
hi to all..how can i close a jInternalFrame if i double click the upper left icon which can be found before the title of the frame..i don't know what listener to put..pls someone help.
Hello friends,I am getting very surpirsing error from Jdk1.3.0.When I tried to run :long value = 40;long ans = (value)*24*60*60*1000;I get negative value in long. but when I cast it explicitly, I get proper ans. but why should i cast?If you know anything about these then please help ...
http://chrissy3.topcities.com/mystuff.html(problem near the bottom of page)I have to give the problem as a link because it contains an image.CAN ANYONE PLEASE HELP ME WITH THE PROBLEM, BASICALLY WITH THE MAIN CODE?I want the code to search for the blank space (e.g search for 0) then I want it ...
144 byte By
plutiana at 2007-9-28 6:12:18
Hi all,I'm now finding a free DBMS for my final year project. Are there any free DBMSs which is easy to use and manage?Thx
338 byte By
marjowa at 2007-9-28 6:17:45
Please help me. I really am not good in java programming. I need to build a chat clent and server applet. The client should be able to attach files, update profile and enables them to chat privately with another user. I don't know where to start. I also want to know how it can accept and ...
I have a Vector of Integers, like so: {1, 2, 4, 7}, and I need to generate all subsets of a given size. So if I wanted all the subsets of size three for the above set, I would get: {{1, 2, 4}, {1, 2, 7}, {1, 4, 7}, and {2, 4, 7}}.How can I generate all these subsets? I found the following code ...
Can I use Java API to create a Java Program....The Program can sensor user's typing action....The important thing is that I want to get any information user typing on any program, ex : words,power point......any program.......Can I use Java do so? and how can I do ?OS : Win2Kthanks a lot ...
The java.net.URL is the package we use to read from and write to existing web pages. I have a Java program that imports the java.net.URL and reads and extracts some information from web pages. However, it is only the latter half of the task.How does a Java program interact with; for example, ...
hi to all...i have a lot of questions here...1.)is there a way to set the location to were the tooltip will showup?2.)is there a way to speed up the display of the tooltip.. becasue sometimes it will show much slower..3.)and most of all is there a way for the tooltip not cover its own ...
752 byte By
denken3a at 2007-9-28 6:36:14
Hello alljavaexperts,We have our system in which we have applet developed.All files and classes are on server.We are running our application(i.e Applet) from client m/c.We are calling ejb through our applet.Before attaching EJB to our applet system was running fine on client m/cs which do not ...
Hello, Because I have to find the Administrative Contact of a long list of .com, I must use a search engine in a Java program instead of typing my query data in the text field provided by the search engine.I have written a test program (shown below); however, I have problem with writing the ...