There was some discussion not long ago on how to add spaces such that
a string fills a given fixed length. I discovered today that it was
in fact possible to use the equivalent of the sprintf command found
in c:
format(baseString[,valuesList])
format("Hello world") -- returns "Hello world"
Marielle Lange wrote:
There was some discussion not long ago on how to add spaces such that
a string fills a given fixed length. I discovered today that it was
in fact possible to use the equivalent of the sprintf command found
in c:
The format function is indeed very useful - but I don't
On Aug 27, 2005, at 7:49 PM, Alex Tweedly wrote:
The format function is indeed very useful - but I don't think it
can be used to solve the particular problem of adding spaces after
a string to fill it out to a specified length.
Or at least - when I was looking at the problem the other day,
Alex,
The format function is indeed very useful - but I don't think it
can be used to solve the particular problem of adding spaces after
a string to fill it out to a specified length.
Or at least - when I was looking at the problem the other day, one
of the alternatives I considered was
Charles Hartman wrote:
On Aug 27, 2005, at 7:49 PM, Alex Tweedly wrote:
The format function is indeed very useful - but I don't think it can
be used to solve the particular problem of adding spaces after a
string to fill it out to a specified length.
Or at least - when I was looking at t
On Aug 28, 2005, at 5:01 AM, Alex Tweedly wrote:
. . . the particular problem of adding spaces after a string to
fill it out to a specified length.
It would work if the "incantation" argument of format() would
accept a variable name, but I can't find a way to make it do
that . . .
Yo
Charles Hartman wrote:
On Aug 28, 2005, at 5:01 AM, Alex Tweedly wrote:
. . . the particular problem of adding spaces after a string to
fill it out to a specified length.
It would work if the "incantation" argument of format() would
accept a variable name, but I can't find a way to ma