locked
NTEXT Carriage return corrupt RRS feed

  • Question

  • Hi,

    I have a very simple report where a comment field is displayed. DataType is NText.
    When the field contains a carriage return marker (char(10 + char(13)) then the PDF Export get corrupt.
    Strangely when the user reprints the same PDF file (the export is stored after printing) the output is OK.
    In either cases when I copy the mentioned comment into Word or Notepad it gives me only squares (Char(1))

    If the mentioned field does NOT contain a carriage return it all works fine
    It tries a conversion to NVARCHAR(MAX) but that does not help.

    It all started after the upgrade from SP2 to SP3

    My situation:
    Windows Server 2003 SP2 Standard X64 Edition
    SQLServer 2005 Standard Edition SP3 (64 bit)  (9.00.4035.00)

    Other customers use other configurations that seem to have no problems

    Jefta

    Tuesday, August 9, 2011 8:39 AM

Answers

  • Hi Jefta,

    Thanks for posting your question here. This issue may be caused by the font type discrepancy between SQL Server 2005 SP3 and PDF, to figure out it, there is one work-around: replace the carriage return with “VbCrLf”. In SSRS, “VbCrLf” has the same effect as carriage return.

    For example, type in the textbox of comment field with below expression.

    =Replace(Fields!conment.Value,CHR(10),VbCrLf)

    There is one similar thread, please refer to: SSRS 2005 - Carriage Return Problem.

    Hope it helps you. If the issue still exists, please let me know.

    Thanks,
    Sharp


    Please remember to mark the replies as answers if they help you and unmark them if they provide no help.
    • Proposed as answer by Sharp Wang Monday, August 15, 2011 3:32 AM
    • Marked as answer by Elvis Long Saturday, August 20, 2011 9:58 AM
    Thursday, August 11, 2011 10:17 AM