Questions tagged as 'string'

2
answers

Removing replaceAll ("[() .- \"] ")

I'm using openJDK1.7 , I'm in need of help. String[] vetor = {"\"Jui.ce \"", "j-90.0", "Abobr.e-u"}; for(int = 0; i < vetor.length; i++) vetor[i].replaceAll("[()-.\"]", ""); The above code among others is not giving a problem b...
asked by 26.01.2017 / 23:24
1
answer

How to create file with date in iso string in name?

I'm having trouble creating a file with the following template: 2017-01-17T09:42:15.3419026-02:00_teste.txt When I run the application to create, this message appears: The given path format is not supported. var dataHora = DateTimeOffs...
asked by 17.01.2017 / 12:46
2
answers

How to read string from a specific word?

My question is as follows: If I have the phrase "The mouse rooted the clothes of the king of Rome" How do I read only from "Roe" to "Rome"? This without using numbers, because they will be several sentences of different sizes. I sear...
asked by 02.03.2017 / 21:00
1
answer

How to convert a string to an integer in a socket program?

Here is a snippet of code: def CriarServer(self): Host = self.Txt1.get() Port = self.Txt2.get() sockobj = socket(AF_INET, SOCK_STREAM) #Erro sockobj.bind((Host, Port)) sockobj.listen(5) while True: da...
asked by 03.01.2017 / 20:13
1
answer

How to write about an image [closed]

I found this code on the internet and made some changes, but I'm not sure what's going wrong. Code: public class main { public static void main(String[] args) throws IOException { String key = "Lucas Caresia"; Buffe...
asked by 29.11.2016 / 19:49
1
answer

How do I replace a string letter when it is masked?

I'm creating a game of gallows for further learning of programming logic. 1- I will mask textfield with *** so the user can not see the word. In my example, I created 3 buttons , respectively "A", "B" e "C" . Let's...
asked by 22.11.2016 / 17:28
1
answer

Deleting spaces in excess of a text

I have the code of a function that should fit space in the sentence, but it is not working. I would like to do with user's input in the same way that the remove function works. Suppose I have the following sentence: input: meu...
asked by 12.02.2017 / 09:03
1
answer

Go through Enum values in C

Do you have some way to go through the values of Enum in C and display in string format, like in Java, C # and other languages?     
asked by 10.12.2016 / 14:56
1
answer

How to concatenate html tag in php? [closed]

$t ='<span style=\"color:#FF0000;\"> '; $t. "texto '</span>' "; echo $t; The above code does not work, nothing is printed. I believe the problem is at the closing of tag span . How to solve?     
asked by 05.12.2016 / 00:19
1
answer

How to send values in a hidden way to the SQL database inside forms with POST [closed]

Good morning guys, I have a question in PHP. I have a page on my site that contains a form that sends through post information the same to a validation page that connects and sends the information to the database. However my site has a desktop v...
asked by 26.09.2016 / 12:53