Questions tagged as 'string'

1
answer

What does the term "String ... string" mean in Java?

What does the term String... string mean in Java? And how to construct a method that returns a String... as an example: public String... getStrings(){ return String... s;) } I know it's not that way, but I wanted to know...
asked by 01.02.2016 / 14:52
3
answers

What is the best way to replace a character in a given String position?

I need to replace a character at a certain position in String (). Example - Change character [21] to 'X': Original String = 01078989469150999134B B 2116456 Modified String = 01078989469150999134B X 2116456 I'm using the follo...
asked by 01.08.2014 / 20:56
3
answers

Query in a SQL string in C #

I am doing a query in the database via string sql.append , in the method call I have two parameters, two strings these receive a textbox typed by the user and do the verification in the database. How do I concatenate correctly? Be...
asked by 11.04.2014 / 17:19
1
answer

JavaScript: how to count the characters of an html text?

The problem: I have a html formatted text and I need to count how many characters (ringtones for journalists) I have. I'll use JavaScript. Some solutions came to mind, but as this will be done repetitively, I decided to analyze better before lea...
asked by 09.03.2015 / 15:22
1
answer

Conversion of date string to datetime C #

I have a method that will receive a string in the format "June 15, 2001", for example, which is equivalent to the date to be compared, I need to pass this string to a DateTime, how would I do this conversion?     
asked by 09.06.2015 / 16:08
2
answers

How to use reflection on a COM object?

I'm trying to do a reflection in a program, however, at the time of picking the object type (which is needed for reflection) is returning "System .__ COMObject", and this is not useful. The method I tried was the following: Type tipo = sim...
asked by 10.09.2014 / 20:18
1
answer

Find list elements with partial strings

I have a List<string> that receives the phone number of all the contacts in the phone, until then without problem, but I want to perform operations with the elements of this list, but I have some problems. An example of a possibl...
asked by 24.09.2015 / 06:38
2
answers

Static string being created with wrong encode

Hello, When creating a string in a Java class (for example: String t = "Ola Java!" ), it seems the compiler is choosing the 'wrong' encode to interpret the bytes that are in the source and generate the String (the 'right' encode should...
asked by 30.03.2014 / 19:10
1
answer

Difference between AnsiString, WideString, UnicodeString, ShortString and String and how to convert

While learning Delphi, I see implementations that use AnsiString , WideString , UnicodeString , ShortString , and String but do not know the difference between them. Another thing that always occurs to me is that...
asked by 19.02.2015 / 21:18
2
answers

How to get a Date String?

My question is how to get a string and manipulate it. The user will enter dd / mm / yyyy in the form of String . How do I do this capture? And then I need to turn that date into an integer so I can do the validations, such as if the repo...
asked by 24.02.2015 / 19:20