32,204 Topics

Member Avatar for
Member Avatar for IcantC

Hello, forum. My question is: how can I format my output when outputting in JTextArea. I want to have the same functionality as System.out.format has (custom spaces between values). Maybe it is possible to print PrintSream objects in JTextArea? I am currently using append(String s) method but I am not …

Member Avatar for IcantC
0
722
Member Avatar for scoobie

Hi, I was wondering if someone could help me. I am using java SWT and am trying to output a list of files and its properties to the screen. I have a file browser popping up and when i select a directory and click ok it outputs the path and …

Member Avatar for Murdok@i
0
409
Member Avatar for ankit.pandey3

[CODE]import java.io.File; import java.io.IOException; import java.io.FileOutputStream; import java.io.FileNotFoundException; import java.awt.TextArea; import java.awt.Font; import java.awt.Color; import java.awt.Image; import java.awt.Toolkit; import java.awt.Canvas; import java.awt.Graphics; import java.awt.FileDialog; import java.awt.event.*; import java.awt.image.BufferedImage; import javax.imageio.ImageIO; import javax.print.DocFlavor.URL; import javax.swing.JFrame; import javax.swing.JOptionPane; import javax.swing.JPanel; import javax.swing.JLabel; import javax.swing.JButton; import javax.swing.JTextField; import javax.swing.Timer; import javax.swing.event.MouseInputAdapter; import javax.swing.*; …

Member Avatar for ankit.pandey3
0
227
Member Avatar for Armanious

I'm trying to replace values in an array while removing extra values. This is what I have, but it doesn't seem to work and I have no idea why. I'm just challenging myself to not use any Strings in my project. This will be the last step. [CODE]/** * * …

Member Avatar for jon.kiparsky
0
1K
Member Avatar for warlord902

Let me tell you I already got the tutorial on how to do this [url]http://db.apache.org/derby/docs/10.3/adminguide/tadminconfig814963.html[/url] But sincerely speaking I did not understood how to do any of the two methods described. Let me tell you my confusions and what I didn't understood and I am developing my project in netbeans. …

Member Avatar for warlord902
0
1K
Member Avatar for localp

I have a List [CODE]List<Food> item[/CODE] , which holds the following. 'Food foodID', 'Food foodName', 'Fruit fruit' Fruit is an Object. It is being saved into the 'List<Food> item' . Now i need to create an Object of 'Fruit' , and save all the 'Fruit' elements in the 'List<Food> item' …

Member Avatar for localp
0
165
Member Avatar for endisbegun

so im very new to programming, its a miracle and a half i managed to get java reinstalled after a year and a half of not using it im taking a cryptography class, the teacher wants to show us the code behind some algorithms, like des and 3des, and in …

Member Avatar for NormR1
0
876
Member Avatar for bsunkel

HI, All I want to do is put a straight line under my 3 labels which I have loaded into a JFrame. After my JFrame has loaded I use the method `repaint()` which is supposed to call: public void paintComponent(Graphics comp) { Graphics2D comp2D = (Graphics2D)comp; comp2D.drawLine(0,60,100,60); } Which does …

Member Avatar for Nick Evan
0
368
Member Avatar for navp

Heya guys, I am trying to make a desktop application for my assignment. I have to design an application that will have a JTable, JTextField and Buttons. I am done the GUI part. The input that user enters into the table should get stored into the database using an "insert" …

Member Avatar for Buffalo101
0
1K
Member Avatar for jrosh

I want to synchronize the data in the record store in mobile phone with mysql database. I connected them through a web service. How can i sync them. What is the way?? i looked in at syncML. Didn't found how to use it properly. Is there any other ways?? please …

Member Avatar for jrosh
0
96
Member Avatar for vextorspace

I am trying to deploy an application that uses JOGL for 3D rendering, so it is platform dependant. If a user with 64 bit windows tries to run it with a 32 bit Java it hangs or crashes. The java installations on windows 7 seem to be varied and I …

Member Avatar for vextorspace
0
137
Member Avatar for vegaseat

Hello, I am vegaseat, the goofy moderator from the Python forum of DaniWeb. I wanted to know if anyone in the Java forum has played around with Java based Python, also known as Jython. Jython uses easy to learn Python syntax and can use the Java libraries. To make a …

Member Avatar for bumsfeld
2
490
Member Avatar for tirambad

Can JMF( java Media Framework) be used to capture video from webcam for a WEB BASED APPLICATION...... it is not a desktop application..... does Operating System allows to access webcam for a web based application

Member Avatar for harinath_2007
0
86
Member Avatar for Zurompeta

Hi, Basically, I'm trying to parse a string into a char for submitting into an array, this is what I have so far: [CODE]String strVariable; Char charVariable; strVariable = "Some String"; charVariable = String.ParseString(strVariable);[/CODE] The bottom lines yields an error...is this possible to do?

Member Avatar for siviwe
0
300
Member Avatar for arvindikchari

Hello, Please clarify the following for me- (1) I want to use a rolling file appender with Log4j, so that the log messages are stored into a single log file....Also I want that the log file should be passed as parameter during program runtime. (2) What all classes have to …

Member Avatar for arvindikchari
0
193
Member Avatar for sirlink99

I have this code here [CODE] public void actionPerformed(ActionEvent arg0) { for (int i = 0; i <= 360; i++){ for (int z = 0; z < 9; z++){ xaxisWave1 [z][i] -= 1; if (xaxisWave1[z][360] < 0){ System.out.println("Line out"); for (int y = 0; y <= 360; y ++){ xaxisWave1[z][y] …

Member Avatar for sirlink99
0
158
Member Avatar for petr.hribal

Hi Boys, I would like to ask you, how should I correctly implement entity life-cycle using hibernate filters. At this time I have got the following classes and DAOS, which I considered to be right - but they obviously aren't. Here are entities which are used in my system. [code] …

0
131
Member Avatar for harinath_2007

Hello.. I am developing a graphics application. I am playing a video in my application and when I press any key , it should stop currently playing video and should start displaying other images.Everything went well except when I press any key the video is getting stopped but the screen …

Member Avatar for JamesCherrill
0
279
Member Avatar for sasidharnet
Member Avatar for Annuate

Hi everyone, I'm working on a summer coding project with few friends from school and we have a design issue that we need some input on.(The language is Java) We have for example a 2D vector class called Vector2. It has two properties float X, and float Y. When I …

Member Avatar for jwenting
0
233
Member Avatar for networkZombie

OK so I have to compare Java with C++ and I need to address the following topics - The following topics should be compared: - programming constructs that are in one language and not the other, differences in - programming in one language or the other should be addressed the …

Member Avatar for meo_beo
0
112
Member Avatar for Dorar

hello every body this is part of my datastructure project//i used java lang. i have a problem in using GUI, see : [CODE]JButton button3 = new JButton("Sub Users Access: Students & Teachers"); button3.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { String Option2 = JOptionPane.showInputDialog(null, "\n1-Show list of bookes\n2-Search book\n3-Exit\n\nEnter a …

Member Avatar for NormR1
0
171
Member Avatar for AhmedGhazey

SA i ask if any one can help me in this grammar problem : Expression ::= Expression ( "&&" | "<" | "+" | "-" | "*" ) Expression | Expression "[" Expression "]" | Expression "." "length" | Expression "." Identifier "(" ( Expression ( "," Expression )* )? …

Member Avatar for NormR1
0
139
Member Avatar for Hakoo

Hello Friends, I have 6 to 7 threads which are running parallely. Thing is I have to put Thread.Sleep() between each threads. How Can I optimize it? [CODE]else if (__selectedString.equals("Master DataInput")) { try { if (RecordStore.listRecordStores() != null) { System.out.println("IT FOUND RECORDSTORE ......"); RecordStore.deleteRecordStore("Company"); RecordStore.deleteRecordStore("Product"); RecordStore.deleteRecordStore("Model"); RecordStore.deleteRecordStore("Customer"); RecordStore.deleteRecordStore("Sales"); System.out.println("Delete All …

Member Avatar for Hakoo
0
147
Member Avatar for sirlink99

I have two JSliders that are both going to a common stateChanged Method, but I am having trouble separating them. I assumes they were somewhat like separating something in the actionPerformed method, but it doesn't seem to work. it does however go into the method, it is just the if …

Member Avatar for sirlink99
0
124
Member Avatar for warlord902

I am thinking to use MySQL with my new Java project, it contains some code that creates database locally and store data in it. It is all fine on my machine as I have all requisites installed like MySQL server but what will happen when I give this developed software …

Member Avatar for warlord902
0
283
Member Avatar for crystality

Hi! Does anybody know how to recursively read in files from a specific directory on the internet, in Java? I want to read in all the text files from this web directory: [url]http://www.cs.ucdavis.edu/~davidson/courses/170-S11/Female/[/url] I know how to read in multiple files that are in a folder on my computer, and …

Member Avatar for masijade
0
259
Member Avatar for warlord902

I am new to MySQL and thinking to use MySQL for my new Java Project which creates a database on the local client machine and uses it to perform all data operations. But before proceeding with MySQL I'm in a bit of doubt that I have MySQL server installed so …

Member Avatar for warlord902
0
247
Member Avatar for sirlink99

I have several different classes and they have graphics in them. I told java to repaint in a class class called LongitudinalWaveGraphics, but it repaints a class called ResistorCCGraphics. Why is this? Thanks for the help. if you need any codes then I can post them.

Member Avatar for NormR1
0
314
Member Avatar for BOOMBOOMF

could someone plz help.. i'm stuck in one part where u have to access the array form the main class(random) ive juss posted the two classes i have doubt in.. the question goes soemthin like this: Q:Make a java class file for function that can do addition, then make a …

Member Avatar for Annuate
0
943

The End.