Reposted with full subject line.
There is a function in Lotus 123 called SETSTRING which allows you to take
data from multiple cells and combine them into a one cell string of text.
You can also set the number of spaces between each label in the string. I am
unable to find the equivalent function in EXCEL. If there is anyone out
there that knows the equivalent or another method of duplicating this
function in would much appreciated.
I only have 123R97 and 123R5 on this machine, so @SETSTRING may have changed in
later versions, but in R97 it doesn't combine text from multiple cells itself,
but multiple calls to it along with the & operator could be used to do this. In
terms of how it seems to work,
@SETSTRING("foo",10,0) == "foo "
=LEFT("foo"&REPT(" ",10),10)
@SETSTRING("foo,10,1) == " foo "
=MID(REPT(" ",10)&"foo"&REPT(" ",10),1+(10+LEN("foo"))/2,10)
@SETSTRING("foo",10,2) == " foo"
=RIGHT(REPT(" ",10)&"foo",10)
These aren't robust. If the length of the 1st argument to @SETSTRING exceeds the
length of the 2nd, @SETSTRING returns its 1st argument in whole. If you need
that functionality, the Excel equivalents become, respectively,
=LEFT("foo"&REPT(" ",10),MAX(LEN("foo"),10))
=MID(REPT(" ",10)&"foo"&REPT(" ",10),1+(10+MIN(LEN("foo"),10))/2,
MAX(LEN("foo"),10))
=RIGHT(REPT(" ",10)&"foo",MAX(LEN("foo"),10))