Questions tagged as 'java'

2
answers

move jlabel object with thread

I have this code, the idea is that through the Runnable interface, a thread is created that calls a "move" method, the method moves a JLabel object. The program compiles everything but does not move the JLabel object. I have tried to make the JL...
asked by 06.04.2017 / 20:59
2
answers

FilternameFilter in Java

I am doing a program that looks for the names of files in a directory and I need to pass as a parameter a String that indicates part of the name of the file, but that does not necessarily start with that parameter. For example, I pass the parame...
asked by 13.02.2017 / 13:44
3
answers

Converted a Resulset to an Object when returning the object returns a NullPointerException? with JDBC

public TaxCategory findByName(int taxId) { TaxCategory taxCategory=null; Statement stmt = null; ResultSet rst = null; Connection acceDB = conexion.getConexion(); String query ="Select * from tax_...
asked by 11.04.2017 / 13:31
2
answers

Back invisible a JPanel and make visible another

I have a problem making a panel visible after rendering another panel invisible. This is my JFrame, which contains a JPanel which in turn contains these 3 JButton as you can see: So that you have a clearer idea of wh...
asked by 12.04.2017 / 02:46
2
answers

Exception java.lang.NullPointerException with an open file

I run a main that generates a PDF file. I have that PDF open, if I try to run that main again, it gives me the following error: Exception in thread "main" java.lang.NullPointerException at bbdd.PDF_Clientes_Tabla.crearPDF(PDF_Clientes_Tabl...
asked by 30.12.2016 / 13:16
1
answer

Avoid leaving the same text in two EditTexts

I use two EditText ( et_miembro_id ) and ( et_fecha_id ), but what I write in et_miembro_id is what is also added in et_fecha_id . What I do not want is for the same text to appear in both, I want them to go separatel...
asked by 29.12.2016 / 22:03
1
answer

Error "SQLException: The flow has already been closed" when reading a field of type LONG

I make the following request from Java with JDBC to user_tab_columns : SELECT column_name, data_type, nullable, data_default, char_length, char_used FROM user_tab_columns WHERE table_name = 'mi_tabla' ORDER...
asked by 30.01.2017 / 16:43
1
answer

Problem when creating a JSON from Servlet

Good, I want to go from a Servlet to a JavaScript a Json with the following data. A dealer has several orders assigned, so I want to pass the id and the position of the delivery person, along with the id and address of the o...
asked by 26.01.2017 / 15:00
1
answer

Insert data in MySQL and Java in Eclipse

I'm having a lot of problems to successfully insert my program data into the table in my database. To connect to MySQL , I have this: import java.sql.*; public class ConexionBD { // Ruta de nuestra base de datos private String se...
asked by 25.11.2016 / 19:58
2
answers

consult 360,000 codes quickly java

I have 1 main Query whose response time is optimal, the problem arises when after executing my query inside the while I execute a second query that reads the code field and queries 1 by one, here my code: $_Query ="select * from remesas"; Resu...
asked by 30.11.2016 / 16:26