Groups | Blog | Home
all groups > sql server reporting services > october 2005 >

sql server reporting services : vbNewLine bug -- please provide a workaround


davedave
10/26/2005 7:08:02 PM
If I set the value of a textbox to
=vbNewLine & vbNewLine & vbNewLine & 12345 & vbNewLine & vbNewLine & 67890.

then I would expect it to be rendered as
-- blank line --
-- blank line --
-- blank line --
12345
-- blank line --
67890

but instead, when rendering to PDF, it comes out as
12345
-- blank line --
67890
-- blank line --
-- blank line --
-- blank line --

Looks like RS is trying to auto-trim starting blank rows, but not doing a
very good job of it. Anyone have a workaround? Like perhaps some way of
prefixing an invisible character that won't be trimmed off by RS.

davedave
10/27/2005 6:05:02 AM
Prefixing the string with ControlChars.Back tricks RS into working properly.
Other special characters like a space, tab, LF are trimmed.

[quoted text, click to view]
AddThis Social Bookmark Button