2810 byte By
Animie at 2007-9-26 1:22:05
Hi everybody!I was working on this AddRecord class, unfortunately I keep gettin an error concerning the ScrollingPanel. I'm not really sure what's wrong with it. The errors are:addrecord.java:9: cannot resolve symbolsymbol : class ScrollingPanellocation: class AddRecord{private ScrollingPanel ...
can i add panel with null layout inside the JScroll Paneexample JPanel jp = JPanel(); jp.setLayout(null); jp.setBounds(new Rectangle(0,0,500,500)); JScrollPane jp = new JScrollPane(jp); this is part of my code, it is compiling and executing butthe Scrolling of the pane is not happening when i ...
757 byte By
viren_22 at 2007-9-26 1:22:12
Dear i want to know 2-3 things.1) I have one java mail API (for linux) having three jar files (ex activation.jar...and others). are these more than suffiecient to have a webmail application. 2) right now i have set my classpath for those jar's and it is working well to send a mail or ...
Can an upcasted object's Class be found out after it being casted to ?
214 byte By
98028140 at 2007-9-26 1:22:15
how can i iconize a frame into yhe trace bar (i dont know the exact name it s the bar at which the clock works) ?and how can i add an popupmenu to it?please give an clear explanation....
Hi,First sorry for my english.I am trying to make an applet with a button which opens a swing custom dialog. Ive reading the swing Java tutorial and I have seen some examples, but all of the custom dialog classes take a frame argument from a window, that uses to call the dialog base class, but ...
Me question is should you useJButton addbutton=new JButton("Add");addbutton.addNewActionListener(new ActionListener() {public void actionPerformed(ActionEvent e){...} });or thisclass Window implements ActionListenerpublic void actionPerformed(ActionEvent e) { if (e.getSource()==addbutton){...} ...
326 byte By
aamirgm at 2007-9-26 1:22:21
I have working on a Prooject I have requirement to dynimically add and remove nodes into the Jtree but the tree is not refresh.And if we minimize the tree in the task bar it have populated correctly .So my question is that how can I refresh tree on my own when a node is added and deleted from ...
If I add two exactly same strings to the JComboBox how can I get their different indexs?It means suppose i added A and again A to a combobox one after the other why their indexs come out to be same?Please answer this question.
67 byte By
totitan at 2007-9-26 1:22:23
May I know how can I have a background using picture?
hi group,I have JList which is in JScrollpane.when I show the JList , I give likegetmylist().setselectedIndex(vec.size()-1); But in some situation I could have 1000 items in list.As per my code,i select the last item of the list.How can i make visible of the last selected index?thank u... ...
Hi All...I have array of byte and I have one user defined class which is implemented as Serializable.This array of byte I am getting from Server...Now I want to deserialize this array of byte to User Defined object..do any body know how to do it?thanx in advance/sunil ...
111 byte By
Engdamon at 2007-9-26 1:22:29
can someone give me some lists regarding the best site for scjp reviews or mock exams?Tnx
Dear friends,I'd like to display a JProgressBar to monitor the progress of loading an object from disk through ObjectInputStream's readObject() method. Anyone know how to do that?Eric
76 byte By
b_babu at 2007-9-26 1:22:41
can i set a window listener to applet if yes how?thanks
Hi !I have 50 JTextField on the screen and every JTextField have its onw rules. How to can I set an Inputformat for the numeric Fields ? I think it must be possible to define patterns like "###,##0.00"Thank you. Wolfgang (KLD)
1107 byte By
palv at 2007-9-26 1:22:46
Hello,My problem is with exception handeling. I'm using java.awt. and i'm writing an application. My problem is i'm not really sure on how the format for exception handeling is.public boolean action(Event evt, Object arg){String str1 = textField1.getText();String str2 = ...
386 byte By
Munch1 at 2007-9-26 1:22:47
I have got some code, as follows;var SQL=" WHERE "if(document.forms.pubsearch.food.value=="1"){SQL=SQL+"Food = 'YES'"}window.document.location="pubs.php?offset=0&sql="+SQL;But when I open the new window, and use the variable $sql (php) it puts / in front of the inverted commas.How do I ...
416 byte By
JebeDiAH at 2007-9-26 1:22:49
Hi there!!I just wonder about the Document class...How can you create an instance of it, cause I found no constructor in the JAVA API.I wanted to create a JTextArea(Document doc), giving the doc file I wanted to create.Is the doc file able to adress a file, so that I can write all I want do be ...
I am playing with writing an applet that connects to a simple java server that I have written. I can run the server with no problems and it sits happily on my PC waiting for something to connect to it.I have also written an applet that when initiated tries to connect to the server application I ...
950 byte By
JebeDiAH at 2007-9-26 1:22:54
Hi there, I did the following (just an outline, I know, that program is not working.... :))class A{static JMenuItem m_saveMenu;A(){ JMenuBar mB = new JMenuBar(); m_saveMenu = new JMenuItem("Save As...");}}class B{JInternalFrame iFrame = new JInternalFrame();iFrame.addInternalFrameListener(new ...
Hi! I'm quite new to java programming and i was wondering if some kind soul could help me out in this. I'm doing a simple member registration for a library. I'm using jdk1.2.2, Swing to create the interface and MS Access as the database. Here's the problem: I have two JRadioButtons (which ...
Hi! I'm quite new to java programming and i was wondering if some kind soul could help me out in this. I'm doing a simple member registration for a library. I'm using jdk1.2.2, Swing to create the interface and MS Access as the database. Here's the problem: I have two JRadioButtons (which ...
423 byte By
zhoujlz at 2007-9-26 1:23:01
I am just doing a project for my java course, it has a frame with some textfields, labels and buttons. there is a label which is String("Employee No"). How can I make the 'o' in the "No" subscripted?I found a setSubscripted() in the API doc, but still have no idea how to do it. Or, is it ...
381 byte By
p0e08 at 2007-9-26 1:23:02
My icons disappear when I move my program to another computer.I am currently using the setIcon method and know the problem is that the file path of the ocon is relative to my computer, not my program.Is there any way I can set the file path of my icons so they are relative to my program, not my ...
537 byte By
pillai99 at 2007-9-26 1:23:04
Dear Friends,I have just completed a course in java,and installedJDK(downloaded) in my pc.But when I compile,it reads nocommand au nom de ficher incorrect(french) indicatingthe name of file is incorrect.But I've checked for errorstoo.I went to ms doss and1.typed cd\then,2.typed cd inno(my ...
Hi Friends!!I have a problem on my hands.I am not able to compile these classes.will someone look into this pleaseClass 1:package obj;public class ASimpleClass{OneMoreSimpleClass onc;public ASimpleClass(){System.out.println("Hello World"); onc=new OneMoreSimpleClass();onc.gettoknowme();} public ...
HelloI have written a simple status bar (basically a JPanel with beveled edges) and added it to the bottom of a JFrame using the BorderLayout manager and BorderLayout.SOUTH.How do I change the size (and style) of the font used in the status bar? I have tried using the setFont() method but the ...
I am workig on WINDOWS 2000 platform. Although I set a path in environment variables, it is not working. This was working prior to installing MS .net framework on my computer. If somebody have faced problem like this? If yes, please tell me if you know the solutionThaking youAchintya ...
1302 byte By
athan00 at 2007-9-26 1:23:19
Hi all,I ve got the following client (applet) & server (application) and I am trying to tranfer some data between them, but strange things happen...!For example some times the packet comes double (e.g. "Athan;Athan;" instead of "Athan;") or other times comes half! (e.g. "Atha" instead of ...
1302 byte By
athan00 at 2007-9-26 1:23:20
Hi all,I ve got the following client (applet) & server (application) and I am trying to tranfer some data between them, but strange things happen...!For example some times the packet comes double (e.g. "Athan;Athan;" instead of "Athan;") or other times comes half! (e.g. "Atha" instead of ...
I'm new in jmf and i don't know how to create an applet with a movie.
Love.............. when i create statement in jdbc its ok but when I pass paameters message comes optional features of Microsoft Access not implemented
179 byte By
matay at 2007-9-26 1:23:32
Dear All,Can anybody tell me how to format decimal numbers with less decimal digits and with "." decimal separater not ","?Thanks a lot!Mustafa
701 byte By
mtndood at 2007-9-26 1:23:41
While reading the tutorial on XML, I have a basic question that is language-related. What is the difference and/or benefit between the two following ways of importing classes:(1)import javax.xml.parsers.DocumentBuilder;import javax.xml.parsers.DocumentBuilderFactory; import ...
5280 byte By
SanDMaN at 2007-9-26 1:23:42
I need someone's help... this is regarding JDBC... i've got a college project that's due on Tuesday and i can't seem to figure out why my program isn't working... i seem to be getting the same errors no matter what i do... if someone can be kind enough to look at it and see what's ...
133 byte By
pc_nv at 2007-9-26 1:23:43
when i set menu accelerators for menu menus they work. when i set menu accelerators for popup menus, they don't work.
1023 byte By
caritouf at 2007-9-26 1:23:45
Hi there,My assignment is to prove that in a group of 30 people, at least 50% have the same birthdays. And in a group of 50 people, 70% have the same birthdays.I have to use Math.random()*365 for every day of the year and store the values in an array of 30 and 50. I have to check of how many ...
Hi everyone,I've got a JPanel, a JTextField, a couple of JSliders and a JButton. My text field shows in format of minutes and seconds slider content. The button is aimed at resetting each slider and the textfield to a preset value.I added an ActionListener to the button: whenever the button is ...
784 byte By
DevRex at 2007-9-26 1:23:57
I've read all the previous posts about creating exe files from classes. From what I understand (just for windows) you can create a small executable file, but this will require the machine to have the java virtual machine installed; or you can have a 10MB executable with all the dll's attached ...
432 byte By
tG_BLK at 2007-9-26 1:24:02
I have just installed JDK 1.3.1 on my computer.I am completely new to Java.I know this sounds idiotic but I'm stuck on the MyWorldApp, the program won't compile. Checked out the other forums, it doesn't work.The class path method...dos can't even recognise it.I'm running Windows2000 and I ...
Is there a way that you can change the win98 background using java. I just want a small program that, when run, will simply change the desktop background to a file that i put in the code. Or else a program that, when run, opens the display properties so the user can select the background. ...
I'm attempting to convert a C program I wrote several years ago to Java. It's supposed to calculate sunrise & sunset. (If the Vernal Equinox occurred at noon on March 21, then in the struct below, the "offset" would be .5 of a day.) Does my struct need to become a class in Java, and can I ...
452 byte By
simenwu at 2007-9-26 1:24:11
I have some questions about ClipBoard.getContents(Object requestor).1. What's the meaning of the parameter requestor? Actually it works when I pass any Object as the parameter.2. When I select a diretory in the Windows Explorer or an image, I find the getContents will return null. Is it ...
367 byte By
mayra at 2007-9-26 1:24:12
HiI am trying really hard to find a code to read each byte at a time (using buffered input stream) from a file and then store the values in an array and then convert it into an image but i cant make it work. Can you plz write a bit of code for me to do that because i am getting very ...
642 byte By
dupsy at 2007-9-26 1:24:14
I have a problem with implementation of a something similar to a LISP tree in Java. That means that I want to be able to combine different if-else-conditions from a set of variables and operators and run it. For example, if (variable) (operator) (variable) (operator2) (variable) (operator) ...
7299 byte By
NTK1 at 2007-9-26 1:24:17
Hi,Can anyone help who knows about graphics, I have written the following program which draws a polygon. It is a cut down version of a more complicated version. At the moment it draws a rectangle using the general path method and draws ellipses at the polygon points (ie each corner of the ...
2116 byte By
mayra at 2007-9-26 1:24:18
HiI am trying really hard to find a code to read each byte at a time (using buffered input stream) and then store the values in an array but i cant make it work. Can you plz write a bit of code for me to do that because i am getting very confused and the project seems endleess. I am trying to ...
3670 byte By
shahzad5 at 2007-9-26 1:24:21
Hey!i wanna creat a border around year_panel.i have the lines of code(in my programe) for creating the border but they are not working properly.If somebody could also tell me how to put month names (Jan to Dec)on the month_panel(the third panel in my programe),Even for this one i wrote in the ...
1830 byte By
igby at 2007-9-26 1:24:24
I'm having trouble compiling the following simple servlet:public class Testing extends HttpServlet{public void doGet(HttpServletRequest request, HttpServletResponse response)throws ServletException, IOException{PrintWriter out;String title = "Simple Servlet Output"; ...