32,199 Topics

Member Avatar for
Member Avatar for bibiki

Ok, I am trying to build a jar file and I cannot seem to find my way around. I have attached an image to this thread to show my directory structure. Now, I am navigating to my MultiProjectManagement directory and creating my manifest.txt file with: echo Main-Class: multi.project.management.panels.ProjectListPanel > manifest.txt …

Member Avatar for bibiki
0
179
Member Avatar for ktsangop

Hello everyone! Just as the title suggests, i would like to know if it's possible to set the position of a dialog box. The default behaviour, is to appear in the center of the screen I use it this way : public static int confirmationBox(String infoMessage, String location) { int …

Member Avatar for ktsangop
0
3K
Member Avatar for vidyya06

retrive data from database using struts 2 and display using dojo tags

Member Avatar for Begginnerdev
0
58
Member Avatar for sash_kp

I developed a client server based java networking Instant Messaging app. The client program is needed to be run on the client computer whereas the server program is on server computer. This works in my local wi-fi network(Home network). But i want this one to deploy on internet using some …

Member Avatar for sash_kp
0
300
Member Avatar for jemz

Hi, I need some help on this how can i use the arrow keys(up,down,left and right) in the keyboard so that the filloval will move, I have no idea on this.can you help me on this please. Thank you in advance. import java.util.*; import java.awt.*; import javax.swing.*; import java.awt.event.*; public …

Member Avatar for jemz
0
1K
Member Avatar for ishannshah

Hello Fellow Members, I am currently developing a java program that remotely access a desktop(different network), the reason is the program I am curretly working will delete some of the temp logs that are generated with some other validations. Below are some of the information that might help you in …

Member Avatar for ishannshah
0
1K
Member Avatar for thijo

hi, I have to write my output of a java program to a txt file. how to do this in java thanks

Member Avatar for JamesCherrill
0
521
Member Avatar for sash_kp

I found many programmers using PrintStream in their codes. I looked for this,but failed to get the clear idea of its significance,Why to use it? "Unlike other output streams, a PrintStream never throws an IOException and the data is flushed to a file automatically i.e. the flush method is automatically …

Member Avatar for jalpesh_007
0
152
Member Avatar for abra_ka_dabra

I added a string into an arraylist, but when i want to retrieve it, it does not go into if conditional in the code below: ArrayList a=new ArrayList(); a.add("12"); System.out.println(Integer.toString(1)+","+Integer.toString(2)); if((Integer.toString(1)+Integer.toString(2))==a.get(0)){ System.out.println("this is working here"); } What is the problem here?

Member Avatar for abra_ka_dabra
0
138
Member Avatar for mesbahuk

I am currently converting a Java library to C# .Net, please help me to find if there are C# equivalents of the following java specifics: * RuntimeException() * IllegalStateException() * StringBuffer Any resource on Java to C# conversion will be very helpful. Thanks in advance.

Member Avatar for mesbahuk
0
270
Member Avatar for itsnexgen

Hi Friends, I have been assigned a java based project. First based on environment variable values for any type of file extension such as .txt, .doc, .pdf etc. Example: FILE_EXT = .txt If FILE_EXT .txt then all .txt files in folders sub folders with should run a specific commands (such …

0
66
Member Avatar for rapela thomas

i tried running my first java program on winows 8 but it didnt display hello world instead it wrote something like a problem to do with "main"and also the red buttons.i am using eclipse,jre is my compiler

Member Avatar for stultuske
0
158
Member Avatar for london-G

Hello, I am using Itext to create reports, I have created the layout which includes a table. try{ Document doc = new Document(); PdfWriter.getInstance(doc, new FileOutputStream("Products.pdf")); doc.open(); Image image = Image.getInstance("logo.png"); //doc.add(new Paragraph("image")); doc.add(image); doc.add(new Paragraph("Registration",FontFactory.getFont(FontFactory.TIMES_ROMAN,18,Font.BOLD,BaseColor.RED))); doc.add(new Paragraph(new Date().toString())); doc.add(new Paragraph("------------------------------------------------------------------")); PdfPTable table = new PdfPTable(2); PdfPCell cell = new …

Member Avatar for london-G
0
1K
Member Avatar for godzab

Hello, I have started picking up on encrytion, and I seem to have an error when I run the program. Here is the error: Exception in thread "main" java.security.NoSuchAlgorithmException: Cannot find any provider supporting ES/ECB/PKCS5Padding at javax.crypto.Cipher.getInstance(Cipher.java:453) at GenerateKey.encrypt(GenerateKey.java:41) at GenerateKey.<init>(GenerateKey.java:24) at GenerateKey.main(GenerateKey.java:71) Here is my GenerateKey class: import java.io.IOException; …

Member Avatar for godzab
0
291
Member Avatar for Sheetal Krishna

Hi.. I need some inputs on the below. I am trying to write a program which will help me find the number of objects eligible for garbage collection at any given point of time. How do i do this? Any suggestions?

Member Avatar for jwenting
0
273
Member Avatar for DrEinstein

Hi everyone, I'm stuck making a Scroll pane to see all the bar graphs created when they do not fit on screen, or when the frame is diminished. Can anyone tell me how to do this please? Thanks import javax.swing.JFrame; import javax.swing.JOptionPane; import java.awt.event.*; import javax.swing.*; import javax.swing.event.*; import java.awt.*; …

Member Avatar for DrEinstein
1
147
Member Avatar for proconfusion

can you help me with the code for that using the logic: 1) randomly select the start point 2) predetermine the distance you need that car to travel using nextGaussian() 3) identify all the end points that are that distance away 4) randomly select one as you can see, i …

Member Avatar for JamesCherrill
0
227
Member Avatar for maroun.maroun

I have two JTrees that I want to display the same content on them. I set a ScrollPane to each one and wrote this code: sourceScroll.setViewportView(sourceBuildTree); targetScroll.setViewportView(sourceBuildTree); //I want to set the same tree. sourceScroll is the scroll pane of the first JTree, and targetScroll is the scroll pane of …

Member Avatar for mKorbel
0
144
Member Avatar for libathos

I tries to install a wizard for web references in eclipse, i found these plugins: org.apache.axis.wsdl2java.eclipse_1.1.0. and org.apache.axis_1.1 and when I am trying to add a web reference i get an error message: The selected wizard could not be started. Plug-in "org.apache.axis.wsdl2java.eclipse" was unable to instantiate class "org.apache.axis.wsdl2java.eclipse.wizards.WebReferenceImportWizard". org/eclipse/core/internal/utils/Assert guys …

Member Avatar for stultuske
0
245
Member Avatar for proconfusion

Hi, I havea simulation in which cars are moving. The point is that a car has a start point (coordinates x and y) and an end point (coordinates x1 and y1). I'd like to make sure that the distances that the cars need to travel are following a gaussian distribution …

Member Avatar for proconfusion
0
147
Member Avatar for elaf salah

HI Coud you please explain this programme , step by step , i can`t understand it`s method import java.util.Scanner; public class Ex5_4 { public static void main(String[] args) { Scanner input = new Scanner(System.in); System.out.print("Enter an integer: "); int x = input.nextInt(); int y = reverse(x); System.out.println("The reverse of " …

Member Avatar for elaf salah
-1
164
Member Avatar for london-G

Hello, I have one method for checking fields entered, if they are consistent enough then I am inserting into the database. Another on to check duplicates: //check fields and if alright insert in table public void checkFields(String a, String b, String c, String d){ if(a.length() >= 4 && b.length() >= …

Member Avatar for stultuske
0
113
Member Avatar for cool_zephyr

hey i'm trying to generate numbers from 1 to 3 in a way such that number 1 has the probability 70% being generated number 2 has the probability of 20% of being generated number 3 has the probability of 10% of being generated how do i do that?? can anyone …

Member Avatar for cool_zephyr
0
206
Member Avatar for sash_kp

While copying a code snippet from some sites and pdf,docs line numbers are also getting copied.I have to omit those line numbers in my text editor manually always. Any better way so that line numbers won't be copied?

Member Avatar for ddanbe
-1
293
Member Avatar for DrEinstein

Hi everyone, Does anyone have an idea of how to skip a line in a JTextField? In System.out.println, I would normally type n but it didn't work for me when I used it in a textfield: text1.setText(**"n"**+coloumn[counter]); where the output displays well as desired excpet that it doesn't skip a …

Member Avatar for DrEinstein
1
669
Member Avatar for tdoggrme

i wanted to know if u know how to get the length of digits, like if the user enters 12345 the computer will return 5 because the length is 5

Member Avatar for JamesCherrill
0
7K
Member Avatar for m1051f

Do you know how to convert PDF to PPT|PPS documents in Java? I generated a PDF document with IText and now I want to put an option for users to save as ppt|pps

Member Avatar for sheraz786
0
102
Member Avatar for callen91

I'm taking my first Java class. I need to create a rock paper scissors game. I can't seem to figure out how to fix it. Please help! Thanks (: I'm using NetBeans IDE 7.3 btw /* * To change this template, choose Tools | Templates * and open the template …

Member Avatar for stultuske
0
519
Member Avatar for abra_ka_dabra

I want to create a .csv file. I am using the following code: FileWriter fWriter = null; BufferedWriter writer = null; try { fWriter = new FileWriter("fileName.csv"); writer = new BufferedWriter(fWriter); writer.write("This,line,is,written"); writer.newLine(); writer.close(); } catch (Exception e) { } Does it create a new file if it does not …

Member Avatar for stultuske
0
164
Member Avatar for trini_flava
Member Avatar for stultuske
-1
65

The End.