Questions tagged as 'java'

2
answers

Even numbers, and number of terms to display

I have a question, make the following program that returns the even numbers that are within a limit that the user grants by keyboard, is it possible some way for me to deploy, the number of even terms instead of those that Are they considered wi...
asked by 20.10.2018 / 23:45
1
answer

restart the loop

Hello, I am creating a game that I have as an exercise, it is to guess the number. The program works perfectly for me, but I need at the end of the game to ask if I want to play another game or not, that is, to come to the beginning of the loop....
asked by 18.10.2018 / 11:07
1
answer

I am repeatedly verified by an array

I'm sure I have some silly mistake but I can not see what it is .. My idea is that I extract a data from a TxtPanel. Check if that data is in an array. If it is inside the if and does several things, it will get an error message. But I do...
asked by 25.10.2018 / 10:48
1
answer

Remove a character from a string in java

I hope you can help me I have a java fix and I want to remove a character that is different from "a" or "b" and update the string. For example: if an aa9b comes to take away the 9 and assign it the value aab or if it comes to ababa8abaa to remov...
asked by 14.10.2018 / 17:45
2
answers

Verify data type of an EditText

Hello everyone, I have the following: // recojo 2 valores del EditText String valor1 = recullFrom.getText().toString(); String valor2 = recullTo.getText().toString(); // Transform...
asked by 26.09.2018 / 13:25
1
answer

Convert Image saved in resource.mipmap to Bitmap

I have an image in the mipmap folder of my project, I would like to convert that image to Bitmap . I tried this way but it does not work for me since it tells me that    (R.mipmap.imagen_deseada) can not be applied to thi...
asked by 21.09.2018 / 19:06
1
answer

Error inserting timestamp

I have the following sentence ready ...    Query to insert TimeStamp public void insertarValores() throws SQLException{ PreparedStatement ps = null; conectar con = new conectar(); Connection conn = null; conn = con. conect...
asked by 22.09.2018 / 00:24
1
answer

java properties / xml as constant

I try to collect values from a .properties to use it in an annotation, but it is not possible to do it with ResourceBundle since the annotations work with constants and the result of this, it is not. I tried to change the properties to .xml by c...
asked by 04.09.2018 / 13:01
1
answer

org.springframework.beans.factory.UnsatisfiedDependencyException org.springframework.beans.factory.NoUniqueBeanDefinitionException

How to resolve ambiguities in the AUTOMATIC CONNECTION of Bean in Spring? Image we have a Dessert interface, and we have three different desserts (Beans) that implement the interface (Dessert). The dessert of the day is Cookie, so we wrote...
asked by 02.09.2018 / 14:40
2
answers

JAVA - Print 2 tickets generated in thermal printer and that cut them

I would like some help, it is the first time I have used a thermal printer and I have no idea how to do it, what I want it to do is print a txt file or a String that is generated with the data that make up a ticket (quantity, price, etc), I want...
asked by 06.09.2018 / 04:44