32,199 Topics

Member Avatar for
Member Avatar for Xufyan

what does it mean , use printf in JNI from C ??? i searched alot and found this, [url]http://java.sun.com/docs/books/jni/html/start.html[/url] but didn't find the specific answer :( i need the answer by tomorrow !:( help!

Member Avatar for masijade
0
735
Member Avatar for plasticfood

[CODE]else if(choice == 3){ System.out.println("what is your name? "); String name = kb.nextLine(); boolean x = Member.checkMember(name); System.out.println(x); } [/CODE] when i run this, it prints "what is your name?" and instead of waiting for me type in something, it just skips that part and go ahead and prints x. …

Member Avatar for javaAddict
0
113
Member Avatar for CF019

This probably wasn't clear from the initial prompt, but this is a multi part question I am trying to write a program that will scan what is being typed [not only into Eclipse, but into word or in a browser or whatever] My purpose for doing this is something along …

Member Avatar for peter_budo
-1
146
Member Avatar for Abdel_eid

hey guys , i had a problem with classes and objects , i need to get the class name form a text file for example and open an object from that class , is that possible if so how can i do it . the object parameters i can send …

Member Avatar for JamesCherrill
0
123
Member Avatar for nikita.chandra

Hi all! anyone can please tell me how to retrieve and display a blob data (which is a html page) which is stored in MySql databae by using JDBC on a jsp page Thanks.

Member Avatar for masijade
0
66
Member Avatar for Xeros606

I know that it's possible to "force" a class to have a certain function through interfaces, but is there any way to "force" a class to have and assign certain variables? Also, is there way to "force" a class to assign inherited variables?

Member Avatar for apines
0
108
Member Avatar for JuanKawada

I've been driving myself crazy with something I originally thought would be incredibly simple. Here's a really simple example of what I'm trying to accomplish: I have a picture sized 800x530, all I need to do is center this picture in a new image that is 800x800 with a black …

Member Avatar for JuanKawada
0
131
Member Avatar for eman 22

I know that multithreads in java allows me do multi tasks in the same time, but in the following code I'm not make a sense that the three threads done in the same time [CODE]public class myThreads { public static void main(String [] args) { System.out.println("Begin main Function"); mThread Thread_One …

Member Avatar for apines
0
158
Member Avatar for sciwizeh

Hi, it's been a long time since I've had a problem worthy of this forum, but I've got a real stumper. I've got some sockets, and after running through a get (through print writer sending a command, then an ObjectInputStream recieving an object) from the server code once, and trying …

0
68
Member Avatar for Areint

Hello, I'm having some problems creating an executable jar. I have written all my code in Eclipse and am able to run the program in it, but I cannot create a jar that runs it successfully and I cannot use Eclipse to export a jar that does it either. Here …

0
38
Member Avatar for Kremlan

I'm supposed to modify this method ([url]http://pastebin.com/6xF1pN51[/url]) to this (translated): "A faster algorithm to compute the average can be done by looping through the entire image in two passes in each session and make a one-dimensional mean value. In the first pass compute the mean value of the y-axis (one …

Member Avatar for quuba
0
143
Member Avatar for XxPKMNxX

I have written a program to create a 4x4 grid Sudoku style. The numbers for the puzzle are read from a file and placed in the puzzle. As you can see, i have assigned the first numbers 'a' and the second 'b' etc However, i can not access the a,b,c,d …

Member Avatar for XxPKMNxX
0
137
Member Avatar for sciprog1

Hello, How do I send a class (that extends from JFrame) back and forth between Client and Server? I would grateful for any pseudocode. Thank you!

Member Avatar for sciprog1
0
278
Member Avatar for hatux

Hello! I am facing a problem over and would like to ask if anyone knows the solution. On the following code i am looping files for sentences and then words. If a specific word is found i would like to store a String with the specific phrase. In example word[x-3] …

Member Avatar for jon.kiparsky
0
82
Member Avatar for Yutxz

Alright, this is a school assignment. Unfortunately, we were given about a paragraph of info on apps so I'm not sure what I'm doing wrong. I know it's a pretty random app, but these are the elements that she wanted. My problem is that it runs infinitely when I run …

Member Avatar for JamesCherrill
0
103
Member Avatar for bogun81

I need to provide web user interface... When client choose search option I want to call method which runs on remote cluster. So I need to use apache tomcat which runs on my localhost for servlet implemenation. From servlet I want to make RMI communication towards cluster machine and then …

0
46
Member Avatar for bleedi

Hi! I'm building a program which connects to a MySQL server. The program saves the server passwords in SHA format. There's one class responsible for converting and checking the passwords, and another one for DB connection. Now, when the user starts the program, (s)he types in the username and password. …

Member Avatar for bleedi
0
1K
Member Avatar for Mengha

Could you please show me a very small program with the explanation how the data can be passed between classes. I said very small program (as small as you can) because I just started in Java and if the program is big I'll get lost !!! I'm a bit confused …

Member Avatar for kramerd
0
6K
Member Avatar for Member 784374

Hi all, I was wondering if any of you could tell me how to convert a date format that is being returned in my XML. The element content is being returned as a string of form "2010-11-16T09:00:00Z". The XML is a copy of some metadata of an object in my …

Member Avatar for JamesCherrill
0
90
Member Avatar for gedas

hey guys, i am working on coordinates in one program and there is a line such as this one: [CODE]int xx =Math.round((int) getWidth() * 100 / 768);[/CODE] can somebody tell me what calculation is actually taken before the value is set to int xx thanks a lot for any suggestions

Member Avatar for gedas
0
151
Member Avatar for Codeslinger

/*THE OUTPUT SHOULD BE LIKE THIS: 2 4 6 8 10 - 30 //gets the sum of first column 12 14 16 18 20 - 60 //gets the sum of second column 1 2 3 4 5 - 15 //gets the sum of third column 6 5 4 3 2 …

Member Avatar for apines
0
92
Member Avatar for Monkey-huh?

[CODE]import java.util.*; public class Sort { public static void main(String[] args) { //driver method int[] array = new int[10]; System.out.println("Please enter ten integers"); insertionSort(array); } public static void insertionSort(int[] array) { Scanner kybd = new Scanner(System.in); int min, temp, n = array.length; for (int i = 0; i < n; …

Member Avatar for masijade
0
102
Member Avatar for serph09

Edit: Oh, nvm. I just redid the code and figured out how to write the tester class. Sorry guys for the trouble:( This thread can be deleted. So I have this code (not all was written by me). But I don't know how to start writing a tester class for …

Member Avatar for javaAddict
0
164
Member Avatar for rony

Hiya, I am using following Java file which creates a GUI, in the input field if i put any character why dont I see the JOptionPane.showMessageDialog pop up window as mentioned in the code? Any clues? Thx Rony //import statements import java.awt.*; import java.awt.event.*; import javax.swing.*; import javax.swing.event.*; import java.text.DecimalFormat; …

Member Avatar for javaAddict
0
749
Member Avatar for blknmld69

I would like to know how to take a selected Item string ("Allen Hall: $1,500 per semester") from one combobox and another selected Item string ("7 meals per week: $650 per semester") from another combobox and have the output to be ($2,150) the total of the two strings added together?

Member Avatar for javaAddict
0
104
Member Avatar for soteri0s

Hello everyone, I know this question has been asked before but it is possible to write a keylogger in java? Before assumptions are made I'm not trying to hack anyone or do anything illegal. I simply have a team project in my data structures class and I am an aspiring …

Member Avatar for peter_budo
0
236
Member Avatar for serph09

I have these three classes: Student.java [CODE]public class Student { private int grade; private String name; public Student(String n, int g) { grade = g; name = n; } public int getGrade() { return grade; } public String getName() { return name; } }[/CODE] GradeBook.java [CODE]public class GradeBook { private …

Member Avatar for ~s.o.s~
0
123
Member Avatar for oneml

Hi I am trying to create a program in java which will scan for words within a text file. The program will scan the list containing a bunch of words in every line some words may be repeated. The program should scan the text file when I input a word …

Member Avatar for ~s.o.s~
0
173
Member Avatar for sri.k

Hi all, This is sri. I've done some program to read xml elements in java.But i didnt get them in a structured way like root element and its name and child elements and their names.I am getting end tag names after tag value also.so pls help me in getting elements …

Member Avatar for sri.k
0
176
Member Avatar for Codeslinger

PLEASE MODIFY MY CODE TO COMPUTE FOR THE AVERAGE OF FIRST GRADING, SECOND GRADING, THIRD GRADING AND FOURTH GRADING PERIOD, THE FORMULA IS THIS AVERAGE COMPUTATION First Grading Period: Average = Sum of grades / Number of subjects Second Grading to Fourth Grading Period: Average = (30% of the Average …

Member Avatar for apines
0
203

The End.