HOW TO CREAT SLIDERS?(PLEASE HELP)

1938 byte By shahzad5 at 2007-9-26 1:13:23
Hey1i have to craet three sliders (in three differet panels)so that when i get the current date the three sliders are set in a way that Year slider matches the current year,the monthe slider matchs the current month and the date slider matches the current date.If some body could give me a start ...

wait & notify?

675 byte By mbongcojr at 2007-9-26 1:13:25
Hi,i have a thread class that listens for incoming socket connections and registering them in an array via another class. BUT, my code is really hogging up cpu and i'm not sure how to make the code more efficient. any tips is greatly appreciated.public class Acceptor extends Threadpublic ...

what can i use instead of sockets?

265 byte By andreycr at 2007-9-26 1:13:26
I'm programing a client-server application but the comunication with sockets fails. I'm getting a lot of missing packages. I don't know what is the cause of it!!can some one help me?best regards.Andrey AlvaradoCosta Rica

java.awt.MenuBar: How can I interrupt the user?

397 byte By audus at 2007-9-26 1:13:38
I have a dynamic menubar (it can change content while the application is running). If the user is navigating in the Menu-system at the same time as the menu-content is changing, the jvm crashes (windows says that java.exe has performed an illegal operation). Question:can the program close a ...

How do you install and run Java HTML converter 1.2?

391 byte By philcollins at 2007-9-26 1:13:49
Hi,I just downloaded the Java plugin HTML converter (version 1.2) and after I unzipped the file, there was no exe file to run. Am I supposed to move all the files and directories somewhere else and run something at the command prompt?I wish they had better documentaion about this. I've ...

Installation?

4128 byte By BouncingSoul at 2007-9-26 1:13:52
Im posting this on behalf of a friend. I am a Java programmer besides programming in other languages, but i have no clue how to go about distributing an app or creating an installation program. Here is what he wrote me. Any suggestions would be a great help. ThanksIt's really about deployment. ...

generic data types

494 byte By tjdeep at 2007-9-26 1:13:57
Hello,Does anyone know how to create a generic container of primitive data types? I'm reading in data from a binary file; its got a header that tells me the data type of the binary data. I realized that I cannot use a void[] data as a generic data type; so I tried creating an empty array of ...

Java certification?

471 byte By MatLL at 2007-9-26 1:13:59
Hi all,I'm interested in becoming a certified java web developer. I have experience with server side Java programming, JSP's, servlets, HTML and have done a lot of work in the web sphere development environment. Is there a certification available that talks speciifcally to this type of ...

Finding the Size of a Window

402 byte By thistleS at 2007-9-26 1:14:04
I have written code to display images inside a JFrame. I have code that will resize the image, but I would like to link this resizing to the user resizing the window . Is there any way to monitor the size of the window. I have tried adding adding a MouseMotionListener to my JFrame, but it only ...

drawString issue

440 byte By spany at 2007-9-26 1:14:22
Why is it that you can use Graphics.drawString on a Graphics Object but when the Graphics object was obtained from an image created from an array of pixels, drawstring cannot be applied? I am assuming internally both types of graphics devices (ie ones created from system devices and ones ...

Trapping <Ctrl-F4> to prevent accidental loss of data

2113 byte By CharlesHarrison at 2007-9-26 1:14:23
Writing an MDI program using a DesktopFrame and multiple JInternalFrames in the recommended way. I've created ActionListeners to trap File, Close and File, Exit and the Close button on the internal frames, but the user can still lose all their work by pressing <Ctrl-F4>! How can I bring ...

how to set initiao heap size?

172 byte By bravlee at 2007-9-26 1:14:26
Today ,when I start javac,it appear a error:Invalid initial heap size:-Xms8mcould not create tht java virtual machineThank you very much.

Hang Man

370 byte By JLam at 2007-9-26 1:15:02
I am attempting to develop a hang man game but, I can't get the String Buffer to work in seperating my characters. When prompting input from the user(The word to be guessed) how do I put the individual characters of the inputted word into an array. Do I have to use the String Buffer at all?Any ...

system.out.println

532 byte By shris at 2007-9-26 1:15:08
I need solution for the following -I want system.out.println statements to work in its usual way if a user-defined flag is set in a properties file.In case the flag is not set then I don't want statements to be printed anywhere at all.One option could be - Define and function where it will ...

which statement holds good for ..and why ?

240 byte By chandankalra at 2007-9-26 1:15:11
class CheckOperator{ public static void main(String args[]) { boolean b1 =false; boolean b2 =true; }}a)b1 == b2b)b1&b2c)b1 | b2d)b1 || b2

Adding ActionListener, Where am I wrong?

5920 byte By reddyumamaheswar at 2007-9-26 1:15:21
Hello, Please see the two java files that are working fine, but I need to add actionlisteners to RectangleButton.java file, Could any one please help me? Getting text from textfield of superclass into the a string in the sub-class is my problem.1st Fileimport java.awt.*;import ...

add movies in java

61 byte By edouard_g at 2007-9-26 1:15:37
Is it possible to add movies (.mpeg) in java ?

How to create a .bat file

425 byte By MattTheSwede at 2007-9-26 1:15:39
Hi,I want to transfer and run my program on a computerthat don't have JDK. I want to create a .bat file orsomething like that. How exactly is this done? I guessI have to include all the javaclass files that my programis using. Can I put everything in one directory and thanzip it and create the ...

codes!!

80 byte By Dnw at 2007-9-26 1:15:40
someone can plz give me a simple code ofJava3D and Commapi?

How can I do that ?

280 byte By under31 at 2007-9-26 1:15:42
Hi ! is it possible to change the color of a charactere only on a JTextField ? For resume, i want text with letters in Black, and others in Grey, but in the same JTextField.I know setForeground(), but it is not what i want ...Thanks in advance !

How do I know that there are double-byte characters in s String?

1054 byte By dong721 at 2007-9-26 1:15:55
Hi!If I have a String that contain English and Chinese words,How do I know that the String contain double-byte characters(Chinese words)?Following is my method and the problem I suffered...String A = "test(double-byte chinese)test";byte B[] = A.getBytes();if(A.length() != B.length) ...

package diagram

347 byte By youbin1 at 2007-9-26 1:15:59
Hi, friends,I would like to draw a package diagram for my Java sources (I have about 3000 Java files and 20 packages).The package diagram will be used to show the dependence between the packages.However, tool like Rational Rose does not support this.Do you have any suggestion?Regards,Youbin ...

Why is the runFinalizersOnExit method in class System depricated?

527 byte By sohail_hirani at 2007-9-26 1:16:04
The explaination given in javadocs for deprication of runFinalizersOnExit in System class is that "It may result in finalizers being called on live objects while other threads are concurrently manipulating those objects, resulting in erratic behavior or deadlock". But the finalizers are ...

does jmf2.1.1 really support rtsp?

52 byte By lucky2all at 2007-9-26 1:16:06
where can i find the related examples?

Signed jar installed and Archive, but class not found

858 byte By rmweerd at 2007-9-26 1:16:09
I have created an applet with needs access to system resources, therefor I had to create and sign a jar file. The jar must installed on the client for performance reasons. Another part of the applet must still loaded from the server, so I used the archive tag. But in spite of the fact that the ...

Object

465 byte By M_Timur at 2007-9-26 1:16:16
I have such a problem : in method fileReader I read file. And data in this file have different types. And I want mot to make a lot of getData methods for each type, but to make one getData method which will return an object with all of my data.So 1: I need to make an object(structure) from ...

Swing Applets,Problems when importing libraries like com.borland....

329 byte By gperdikea at 2007-9-26 1:16:23
Hi I've made a Swing Applet that imports some Borland libraries like :import com.borland.jbcl.layout.*;I've downloaded the latest Java plug-in but the browsersays class com.borland.jbcl.layout not found.What must I do in general to avoid that kind of errors?Thanks ...

array.length()

346 byte By mgl0902 at 2007-9-26 1:16:27
what's the problem with the .length method here?String date = new String[5];date[0] = "Hello1";date[1] = "Hello2";date[2] = "Hello3";date[3] = "Hello4";date[4] = "Hello5";System.out.println(date.length());The system says that it can't find length method.Thanks ...

concurrent read-only access vs syncronized

689 byte By Cordeiro at 2007-9-26 1:16:28
I have a certain object that contains two public HashMaps. According to documentation the HashMaps are not syncronized by default, although its possible to have it syncronized using some methods on the Collection interface.These HashMaps are only populated at the beginning of the process by a ...

Newbie Help: Java Object to create an image

1388 byte By ukdevcom at 2007-9-26 1:16:38
Hi there.I'm trying to create a Java class that I can call from Coldfusion that will build a GIF file based on parameters.The idea is, the Java object opens a "background" gif file and then writes some text onto it and saves the whole thing out as a GIF.Bearing in mind this class will be used ...

is it good to have a lot of memory heap?

427 byte By as116416 at 2007-9-26 1:16:41
Hi!I have a java applications that makes transactions. I haveconfigured 256 MB of heap memory. But when the java process carries "n" transactions, it is goingvery slow. However I have changed to 128 MB of heap memory andI haven't had any problem with the java process.Why with 128 MB it's ok ...

Javax.comm API & SMS

448 byte By csr333 at 2007-9-26 1:16:46
Hi All,I would like to make an application to send & recieveSMS messages from a mobile phone which is connected to my computer through nokia data cable.Using the javax.Comm package it looks that theapplication recognizes the port and I can interactwith it, but how can I send a SMS message? ...

CALLABLE STATEMENT

173 byte By gokul_agarwal at 2007-9-26 1:16:48
THIS IS MY FRST QUESTION HERE ...SO A WARM HELLO TO ALL.PLEASE TELL ME HOW TO USE A CALLABLE STATEMENT WITH MS ACCESS WITH THE HELP OF A EXAMPLE.

Help needed : getting the size of an image

329 byte By Lesco at 2007-9-26 1:16:49
Seems that my first post didn't work.. so i try another time.I'd like to get the size (width and height) of an image file, just using the path of that file.Does anyone knows if there is an existing class that can allow me to, or does someone knows the way i should work on itThanks in advance ...

User feedback during applet loading

224 byte By stephengaskell at 2007-9-26 1:16:51
I've created an applet that takes a fair while to load in a browser. Does anyone know an easy way of writing to the screen while the applet loads so the user can be kept informed of the progress of the applet?

Problem in getting Applet POST Method in ASP

1383 byte By manisha1234 at 2007-9-26 1:16:59
I am having an applet with some textfields. I want to pass these form variables using POST method to ASP script which is a preview page. ( with Request.Form("formvariablename") ) I tried following test script but the button seems as if not having any action. What is wrong ? Please help. It will ...

INI JAVA

231 byte By siv-viv at 2007-9-26 1:17:04
well what im trying is that a java application should read a INI file(initialization file) while it starts , how can i specify a java program to read a INI file when it starts.any help is welcome with utmost gratitude

How can I write an instance of a class in a static variable

733 byte By kleindinst at 2007-9-26 1:17:15
Hi !I have an instance of a classDevisen dev = new Devisen();In an other class I have a static method and I need there the content of some variables from dev.public static void abc(){ String text=dev.textfield.getText()}I get the errormessage, that the I cannot use the Not-static variable dev ...

Store int values into dynamic array

417 byte By LearningSTF at 2007-9-26 1:17:19
Hello all, I'm a newbie in JAVA whose want to store int values (coming from a resultset) into an dynamic array. I know that normally to create a "dynamic array" you'd better use a Vector, but it seems that I don't know how to use it correctly (throws me a exception as : Incompatible type ...

Collection of collections.

616 byte By lingamaneni at 2007-9-26 1:17:22
Hi all,I am dealing with a search page which is having 8 search fields. i have a way for individual search fields. but i need to have multiple search.. with any to any combination in all the 8 fields. for this I need a List or an ArrayList which can hold Lists aagain. Eg: List a = null; List b ...

html parsing in browser

696 byte By raj_kaush at 2007-9-26 1:17:27
Hi!I have an html editor getting displayed in the browser.my requirement is to read a html file and display the contents as such in the editor window.But what is happening is,the browser is parsing the html code and displaying it.For eg:- if my html file has code for displaying a button,the ...

java.lang.ClassNotFoundException: sun.jdbc.odbc.JdbcOdbcDriver

776 byte By marikkan at 2007-9-26 1:17:28
Hi, I get the error in the subject when I use it with the following code in an applet.try { Class.forName("sun.jdbc.odbc.JdbcOdbcDriver"); connection = DriverManager.getConnection(url, username, password); }catch (Exception e) { e.printStackTrace(); name.setText(e.toString()); connection = ...

ArrayList Vs Vector

170 byte By anirudhchitnis at 2007-9-26 1:17:35
What is the comparison of the cost of adding an object in Vector and in an ArrayList ( for which adding an element has constant amortized time cost).

JTree refresh

179 byte By hande123 at 2007-9-26 1:17:36
When a Node in the JTree contains text that is wider than the JTree width, is there a way to refresh the JTree to resize itself to show the full text.Regards.

how to transfer a big file from an application program to web server

377 byte By leech huang at 2007-9-26 1:17:41
hi, all a problem confused me and so urgent.and now I have a servlet to process the file uploaded from browser and it can work successfully. and I want to upload many files from java application program using this servlet. I used URLConnection, but how to do, who can give me some example?thanks ...

interesting ? @ servlet reading a txt file

559 byte By amit_vj at 2007-9-26 1:17:42
hi friends,i need ur help for one interesting problem i m facing.I want to read a txt file and wanna display the text from that file into an html, using a servlet.A txt file contains sentences( words with spaces in between ).When servlet reads the file, it is reading the whole sentence ,but ...

What's wrong in my copyInto statment

353 byte By LearningSTF at 2007-9-26 1:17:43
Hi, A make a simple copyInto statment that is crashed and I don't understand why ?Thanks in advance.Here is a snipset of my codeVector v= new Vector();String[] labels=new String[v.size()];log=rs.getString("ORIG_SUBMITTER");v.add(j,new String(log));v.copyInto(String[] labels); ...

Convert JFrame to JApplet

357 byte By gperdikea at 2007-9-26 1:17:46
HiHow can one convert his existing application which uses JFrames and a main method() to an Applet which extends JApplet and invokes init()?Perhaps I could write a small applet which creates an instance of my application but my application uses it's own frames and GUI.How do I make them appear ...

Error: type expected

315 byte By sir_marky at 2007-9-26 1:17:47
when i try to compile i get the following error:Addition.java:38: Type expected.plusButton.addContainerListener(this);^Addition.java:49: Type expected.calcButton.addActionListener(this); ^does anyone know what i should insert to compile properly ...

java.lang.ClassCastException: com.sun.mail.util.SharedByteArrayInputStream

973 byte By agilbull at 2007-9-26 1:17:49
I want to cast an Object to a javax.mail.MultipartCompilation OkBut i have this message : java.lang.ClassCastException: com.sun.mail.util.SharedByteArrayInputStream when using the bean with JSPHere are the sources :public Monmail(Message mess) throws IOException ,MessagingException {DebugWriter ...