theog
theog

Reputation: 1064

Display all SSRS report field values without line breaks

I have an SSRS report with a dataset that I cannot modify. I can only change the report's format.

I am trying to figure out how to have one of the reports fields display its many values inline in a list or csv fashion. Right now it prints a value and does a line break, then the next value and another line break, and so on... I would like my values to print without the line breaks.

I've tried using the Replace function in an expression (replace vbcrlf with ", ") with no success...

Upvotes: 0

Views: 3151

Answers (2)

Nathan Griffiths
Nathan Griffiths

Reputation: 12756

It sounds like you just want an expression to remove the line feed characters in your source data so that it prints on one line. You'll probably need a bit of trial and error to work our what the characters actually are but you probably want to start with replacing:

vbCrLf

vbLf

vbCr

More on replacing line breaks in this question

You could create a Code function in the report to do the replacing, similar to the answer in this question.

Upvotes: 1

Jeroen
Jeroen

Reputation: 63729

You're not quite providing enough information to reliably answer the question. Most likely, your question is a duplicate of this question, and my answer there will answer your question as well. The basics are:

  1. Create a multi-value parameter @MyParameter
  2. Set the default values for the parameter to be retrieved from your dataset
  3. In your textbox use the expression =Join(Parameters!MyParameter.Value, ", ")

Same disclaimer holds here as well: if there are a lot of values this solution may not work very well.

Upvotes: 1

Related Questions