Does formatted string have length limitation?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I tried to do very simple operation, at least I thought it will be simple,
and it is to use String.Format. But, when formatted string bigger than 255 I
got this mistake "Input string was not in a correct format".

WHY IS IT SO?
 
Hello, Pavel!

P> I tried to do very simple operation, at least I thought it will be
P> simple, and it is to use String.Format. But, when formatted string
P> bigger than 255 I got this mistake "Input string was not in a correct
P> format".

P> WHY IS IT SO?

I do not know it there is any strict limitation...

Do you have symbols '{' or '}' in the text that do not server as parameter placeholder?
If you have them then they have to be escaped with the same character.
That is '{' becomes '{{' and '}' becomes '}}'

--
Regards, Vadym Stetsyak
www: http://vadmyst.blogspot.com
 
Pavel said:
I tried to do very simple operation, at least I thought it will be simple,
and it is to use String.Format. But, when formatted string bigger than 255 I
got this mistake "Input string was not in a correct format".

WHY IS IT SO?

Code example please.
 
Excuse me, but it was my mistake. This string was so long and mistake was
only for 1 letter, that I didn't put attention at till I started copy to
here. I wrote {9) instead of {9}.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top