Questions tagged as 'java'

2
answers

The request was rejected because its size

I have the following code in my controller which is responsible for loading a client with a photo. @RequestMapping(method = RequestMethod.POST, value = "/form") public String guardar(@Valid @ModelAttribute("cliente") ClienteEntity cliente, Bin...
asked by 01.03.2018 / 15:35
1
answer

Get file in relative path of runnable jar

I have been trying for hours to read a file that is in the same directory as the executable JAR: My code is: Object obj = parser.parse(new FileReader("configuracion.json")); But I already tried with "./ configuracion.json" "....
asked by 04.01.2018 / 18:07
2
answers

Error getting user's location - Android GPS

I am new to the development of applications for Android and I am creating an application which makes use of the user's location. The problem is that sometimes I get a Lat and Long of (0,0). I mean, he can not read it. But this only happens with...
asked by 21.03.2018 / 07:19
1
answer

turn negative value into a java setter

I have the following code: if(!("TB").equals(this.cabnom.getTipo())){ ArrayList<Linnom> lista = (ArrayList<Linnom>)this.linnomService.findByNumNom(new Linnom(numNomAnterior)); for(int i=0; i < lista.size(...
asked by 11.01.2018 / 10:12
1
answer

Application to send text messages to cell phones [closed]

I would like to know how I can develop a java application that allows me to send text messages to several cell phones.     
asked by 11.01.2018 / 20:10
2
answers

Java Split excluding rank

I receive a String in java with a value format and range [x,y,z] so that the input String is valor[x,y,z] (example 20[4Y,2W,4H] ). I can have values with a condition or (represented with a ',') so that the...
asked by 13.02.2018 / 12:47
1
answer

Problem when updating datafable component of primefaces

I am developing a Primefaces 6.2 application in which I use the datatable component in edit mode. <p:remoteCommand name="refrescarTabla" actionListener="#{bean.dlgEditar.refrescarTabla}" update="pgTabla"/> <h:panelGroup id...
asked by 02.04.2018 / 15:10
3
answers

Validation of rout in java

This is the exercise: Create a Program that allows you to enter a person's Rut and show: If the Rut is valid or not, if it is not valid, allow it to be re-entered, you only have 3 chances to make a mistake, after 3 times the program ends with...
asked by 17.11.2017 / 01:23
1
answer

Folder management

I'm new to programming and I'm doing a project in which I want to create, open and delete folders, but I can not find how I can open it. I use the library java.io.File . Try this: public void crearCarpeta()...
asked by 23.11.2017 / 17:47
2
answers

Get error returned by the server with Volley

I am making an application in which I consume an external service and for this, I am using the library Volley from Google. I'm trying to process the error with the structure: { "message": "invalid public_key", "error": "not_found", "status":...
asked by 16.10.2017 / 03:50