35,618 Topics

Member Avatar for
Member Avatar for kulpreet lkaur

hii i've java 1.6.0_11......n window 7...whnevr i try to save file in java\jdk1.6.0_11\bin then it gives a msg i.e you don't have permission to save in this location.contact to administrator to obtain the permision.... so um nt coming to kwon how to take permision from administrator and save my file... …

Member Avatar for kulpreet lkaur
0
141
Member Avatar for chiiqui

I am once again experimenting and Only to find out that java is pass by value, how do I actually manipulate a method or an array that has been pass to another method? for example [CODE]int[]a ={1,2,3,4,5,6}; modify(a); ________________________ void modify(int[] aTest){ aTest[1]=2; }[/CODE] //take note that those arrays are …

Member Avatar for JamesCherrill
0
250
Member Avatar for rajhans

Hello All, I have stuck in a problem. There are set of strings of different length. I have to remove repeated elements from all the strings except from the string in which it appeared first. For example say the input strings are "3 4 7 2 15 10" "5 7 …

Member Avatar for rajhans
0
208
Member Avatar for sidra 100

m a begineer of java programing plz tel me wats wrong in my program. [CODE]// my first program public class HelloWorld { public static void main(String[] args) { System.out.printIn("Hello World"); } }[/CODE] it shows the error cannot find symbol. symbol:method PrintIn(java.lang.string) location: class java.io.printstream system.out.printIn("helloWorld") 1 error

Member Avatar for vijaykavin10
0
98
Member Avatar for eziekiel123

[CODE]import java.util.*; public class scwhile{ static Scanner input = new Scanner (System.in); public static void main (String[] args) { char letter; String inputMessage; String inputString; String outputMessage; inputMessage = "Program to convert uppercase " + "letters to their corresponding "+ "telephone digits.\n" + "To stop the program enter #.\n" + …

Member Avatar for JamesCherrill
0
234
Member Avatar for gahhon

[CODE] public class Rectangle { private double length; private double breadth; public void Rectangle(){} [COLOR="Green"]public Rectangle(double length, double breadth){[/COLOR] this.length = length; this.breadth = breadth; } public void setLength(double length){ this.length = length; } public double getLength(){ return length; } public void setBreadth(double breadth){ this.breadth = breadth; } public double …

Member Avatar for ~s.o.s~
0
122
Member Avatar for nick6987

we given a program department program which user enters a number to a specific department and now our teacher wants us to convert that to a switch and use enum data type having a little trouble with some of the errors. [CODE]import java.util.Scanner; enum MenuOptions currentPrompt { BILLING, FORECLOSURE, LISTING, …

Member Avatar for stultuske
0
149
Member Avatar for WDrago

All, I can't seem to find anything on the web about how to connect to a LibreOffice database. I am currently using the following code to connect to a MS Access database and would like to know how to change it to work with LibreOffice. [CODE]String strConnect = "jdbc:odbc:DRIVER=Microsoft Access …

Member Avatar for WDrago
0
3K
Member Avatar for rotten69

Hey everyone, I have been looking for video tutorials on SWING class and pretty much of GUI side in Java .. I found tutorials on Oracle site but they require lots and lots of reading.. if anyone knows a good site that has videos on GUI, please share it.. Time …

Member Avatar for ceyezumma
0
428
Member Avatar for StephNicolaou

Hi all, Trying to simply call method, (below) from another class and return the value found by the scanner. Please see below: [code] public int getInt(String prompt) { System.out.print(prompt + "a"); //int result = in.nextInt(); if (in.hasNextInt()) { x = in.nextInt(); y = in.nextInt(); sum = x+y; System.out.print("sum" + sum); …

Member Avatar for StephNicolaou
0
149
Member Avatar for Laxman2809

So I have been tasked with creating a program that is essentially a planner for a person. It has to have the abilities to add events of 3 types(Party, Dance Class,Club Meeting). It then has to be able to display everything enter, and be able to display the things that …

Member Avatar for stultuske
0
120
Member Avatar for IIM

Can anyone tell me how can we perform code analyze using PMD or Checkstyle during develop time.... I want to know it so as instead of checking at the last for bugs,i can correct them as soon as i find it. I searched in google and there i found a …

Member Avatar for peter_budo
0
94
Member Avatar for Peter Hon 123

In the following code, there exist items="${message}". I know it is EL. But I cannot find out where "${message}" is came from . Please help. Thanks. [CODE]<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %> <%@ taglib prefix="fmt" uri="http://java.sun.com/jstl/fmt" %> <%@ taglib prefix="spring" uri="/spring" %> <%@ taglib prefix="z" uri="/WEB-INF/tag.tld" %> <%@ page language="java" contentType="text/html; …

Member Avatar for peter_budo
0
148
Member Avatar for Neversleepin

Hi all, Here is what i found with google to Find and Replace word in Java: [CODE] public class ReplaceAll { public static void main(String[] args) { String str="We want replace replace word from this string"; str=str.replaceAll("replace", "Done"); System.out.println(str); } }[/CODE] It works well but how to do the same …

Member Avatar for stultuske
0
1K
Member Avatar for 2k9-it

hello friend i want to change arabic or farsi alphabet convert into unicode so plzz give hints

Member Avatar for stultuske
0
78
Member Avatar for AQWst

I am new to GUI Java programming and I am attempting to find the best way of creating a frame to contain a series of menus. I am first adding logic to have the date and time appear in the frame, but the way I am doing it they are …

Member Avatar for stultuske
0
420
Member Avatar for Dersev

Hello I have a small problem with ListSelectionListener. I can not copy dataList.getSelectedValue().toString(); to global String variable text. How can I do it ? This is inside of if statement and that is the problem. Anyone knows how to solve it ? [CODE] ListSelectionListener lListener = new ListSelectionListener() { public …

Member Avatar for mKorbel
0
320
Member Avatar for ceyesuma

Hello all. In my Apache derby db I set up Decimal data types like this: [code] admin_pay_rate DECIMAL(5,2), [/code] I use JFormattedTextFields to filter decimal usage in text fields concerning money Like admin pay rate would be 150.00: this is good. In the JFormattedTextField it will allow 1,000.00 but the …

Member Avatar for mKorbel
0
208
Member Avatar for zaxon1987

Okay so basically I'm studying Introductory programming using the 'BlueJ' Java program on Mac. I'm trying to create a 'Dynamic Billboard' program that asks a user to enter a five letter word using the letters; ' S, P, A, R, E', then displays it in white on a black screen …

Member Avatar for JamesCherrill
0
221
Member Avatar for vijaykavin10

In applet we are using init() method so inside of the init() method can we use the actionPerformed method or can't?.If we couldn't which place can be implements that action performend method. Also you just give me the syntax for creating the actionperformed method in applet.And that applet must have …

Member Avatar for mKorbel
0
148
Member Avatar for Nathan_11

I have this code that would randomize the number inputs but should not include 0 and 50 and above digits... how should i do it? Thanks [CODE]import java.util.*; public class RndomA { public static void main(String[]args){ int[]A=new int [10]; Scanner in=new Scanner(System.in); System.out.println("Numbers to be randomize:"); for(int a=0;a<A.length;a++){ Random r=new …

Member Avatar for stultuske
0
140
Member Avatar for Onlineshade

I wish to make a project on Messenger using Java. But is [B]Java Socket programming[/B] necessary for it?

Member Avatar for stultuske
0
81
Member Avatar for solarmotion

I had encounter a problem in my task. How come the output always return false? [CODE] public class Entity { private String itemCode; private String title; private String description; private int language; private int time; private String productCompany; private int status; public Entity(){ itemCode="E250"; title="The Lookout"; description="by Scott Frank"; language=1; …

Member Avatar for solarmotion
0
114
Member Avatar for crazybeaner

I'm creating an odometer program. "The problem to solve is define a class Odometer that will be used to track fueland mileage for an automobile. The class should have member variables to track the miles driven and the fuel efficiency of the vehicle in miles per gallon. Include a mutator …

Member Avatar for javaAddict
0
396
Member Avatar for ynwa

Hi, I am currently using swt-win.jar on my 64 bit Windows Operating system. The error i am facing is that the the following Exception in thread "main" java.lang.UnsatisfiedLinkError: Cannot load 32-bit SWT libraries on 64-bit JVM Is there any swt jar file for 64 bit windows operating system and 64 …

Member Avatar for ~s.o.s~
0
63
Member Avatar for newbie14

Dear All, I have a snippet of code as below. Here I build one db connection and is shared across. I can put the dbconn.commit in place and no problem. The problem when I put the dbconn.rollback I get this sort of error "commServer.java:1798: unreported exception java.sql.SQLException; must be caught …

Member Avatar for newbie14
0
247
Member Avatar for Acidburn

hey guys I'm trying to get hold of a StreamConnection [code] try { StreamConnection conn = ( StreamConnection ) Connector.open ( url ) ; } catch (Exception ex) { ex.printStackTrace(); } [/code] however when i do this i get the following error [quote] java.lang.ClassCastException [/quote] According to my know of …

Member Avatar for Bens
0
163
Member Avatar for lbgladson

I have a program to add coins into a piggy bank and calculate the total but my program is not asking how many of each coin and will not give me the total. [code] import java.util.Scanner; public class PiggyBankTester { public static void main(String[] args) { int pennies; int nickels; …

Member Avatar for sirlink99
0
1K
Member Avatar for lbgladson

I have an assignment to gather information on students and their grades and then display the information using a for loop. I have the following code but it is not displaying the information correctly. Any help would be great. [code] public class Grader { String last; String assign; int score; …

Member Avatar for Slimmy
0
153
Member Avatar for buba_kazouba

[CODE]package amena; import java.awt.Color; /** * FileSystemModel is a TreeTableModel representing a hierarchical file * system. Nodes in the FileSystemModel are FileNodes which, when they * are directory nodes, cache their children to avoid repeatedly querying * the real file system. */ public class FileSystemModel extends AbstractTreeTableModel implements TreeTableModel { …

Member Avatar for Slimmy
0
227

The End.