Questions tagged as 'java'

2
answers

Upload file to Java server ee

Excellent community! :) I bring you a query. I am trying to make a form with Java that receives a text, a date and a file. The file is uploaded to the server, gets the link from the file, and stores it in a database. First I had done the part...
asked by 17.10.2016 / 17:48
2
answers

UnsatisfiedLinkError: no swt-pi-gtk-3550

When I launch an application created with Eclipse RCP it is always aborted with an UnsatisfiedLinkError error. user@maquina:~> ./aplicacion.sh Exception in thread "main" java.lang.UnsatisfiedLinkError: no swt-pi-gtk-3550 or swt-pi-gtk in sw...
asked by 21.10.2016 / 06:03
1
answer

In a Model (MVC) query a View (SQL) or consult several tables

Good morning. I'm adapting my project to MVC and I have a question, in a form I need to recover the data from 3 tables. I have an already created (SQL) view where I can create the getRegistration () method of the 'Dao Member (Data Access Object)...
asked by 20.10.2016 / 11:12
2
answers

Sum of vectors in java

With the recursive algorithm, how is a vector addition program done in java? int suma_vec(int v [], int n) { if (n == 0) { return v[n]; } else { return suma_vec(v, n - 1) + v[n]; } }     
asked by 21.03.2017 / 19:39
1
answer

Java logical vending machine to give change

I am a student, I am making a machine, I almost end it, but I am having problems when my stock of coins is zero, in theory I would have to leave a message saying that it can not give change but it gives the same change and does not discount it o...
asked by 07.12.2018 / 11:31
1
answer

How do I compile these java files?

I would like to know how to compile these java files, because I try from cmd and I get the error:    "can not find simbol". Load Data package tp2; import java.io.BufferedReader; import java.io.File; import java.io.FileReader; impor...
asked by 06.12.2018 / 23:53
1
answer

Align the text / message of a JOptionPane

I have several JOptionPane that show messages, example: JOptionPane.showMessageDialog(loginFrame, " Login Successful"); When I write the message as in the example, I have to put a space before Login Successful so that it...
asked by 06.12.2018 / 08:19
1
answer

Problem JAVA input throws error

Practicing a bit of Java I found an exercise that I found interesting to handle functions, the statement is quite long and is in a book (therefore it is difficult for me to copy it, plus I did a variation) but basically it is a matrix of 4 cours...
asked by 03.01.2019 / 22:02
1
answer

How to do so that I do not repeat the elements of a RANDOM WITH ELEMENTS OF ARRAYLIST JAVA

In this case when I'm going to print the product data I have put a random amount and price because when you start the program each product has different amounts and different prices, the problem I have is that I do it randomly but it repeats me...
asked by 18.12.2018 / 10:11
1
answer

How do I average the method: calculate AverageWeightDownload? POO Java

I have to do this program, my question is how to do point 4), which is to calculate the average of the Locomotive class. At the time it occurred to me to do a summation for Carload weight that belongs to the vagon class and another sum for amoun...
asked by 25.11.2018 / 23:49