Top "String-formatting" questions

Commonly refers to a number of methods to display an arbitrary number of varied data types into a string.

Display Superscript in SSRS reports

I m working on SSRS 2008. i want to display date as 1st January 2011.. but "st" should be in superscipt .. not …

ssrs-2008 string-formatting reporting-services superscript
In PHP, how do I add to a zero-padded numeric string and preserve the zero padding?

If I have a variable in PHP containing 0001 and I add 1 to it, the result is 2 instead of 0002. How do …

php variables string-formatting zero-pad
How to escape curly braces in a format string in Rust

I want to write this write!(f, "{ hash:{}, subject: {} }", self.hash, self.subject) But since curly braces have special meaning …

string-formatting rust
Implementing String.Format() in VB6

Can String.Format() be implemented in VB6, at least a close-enough version of it that could be useful when programming …

string vba vb6 string-formatting
Send a text string containing double quotes to function

I'm having a problem with using double quotes while formatting text strings being sent to functions in R. Consider an …

r string-formatting double-quotes output
Why does gcc -Wall give warning about zero-length format string?

I searched around a little bit for information on this but didn't find anything satisfactory. Is there some special behavior …

c gcc string-formatting printf gcc-warning
Remove all occurrences of several chars from a string

Is there a pythonic way to do what the str.strip() method does, except for all occurrences, not just those …

python string string-formatting built-in
ASP.NET WebAPI: How to control string content returned to client?

In WebAPI, say I return a string wrapped in an HTTP response: return Request.CreateResponse(HttpStatusCode.BadRequest, "Line1 \r\n …

asp.net-web-api string-formatting httpresponse
Python: Formatting a string using variable names placeholders

Consider the following string building statement: s="svn cp %s/%s/ %s/%s/" % (root_dir, trunk, root_dir, tag) Using …

python string-formatting iterable-unpacking
How to produce "human readable" strings to represent a TimeSpan

I have a TimeSpan representing the amount of time a client has been connected to my server. I want to …

c# .net string-formatting timespan