June 2, 2010 at 6:30 am
Is there a way to double space a paragraph in text box for a report. It needs to be dynamic to handle varying lengths. In the paragraph I insert vendor names that can be 10 characters to 35 characters.
I looked at VbCRLF but that does not seem to be what I am looking for (though might be using it wrong)...
Any suggestions?
June 2, 2010 at 7:26 am
The question I have is how is the data stored? Can you get some examples so that we can have to code to play with, I have a few ideas, but to provide you with one that will work will require a bit more information on your part.
How do you decide when to insert a single CR and when to insert 2 CR's?
-Luke.
PS. if you want a double return all you have to do is use 2 vbCrLF's and you'll get the double space.
June 2, 2010 at 8:06 am
The entire paragraph will always be double space.
Here is one of the expressions for one of the paragraphs:
="REQUEST #" & (Fields!NumCount.Value - 4) & ": " &
"That the bill of " & Fields!Provider.Value &
" attached hereto as Exhibit " & Fields!AlphaCount.Value &
" is a true and accurate copy of a bill for " & FORMAT(Fields!Amount.Value, "C") &
" for treatment and services rendered to " & First(Fields!Plaintiff.Value, "dsPlaintiff") &
" on " & Fields!service_begin_date.Value & IIF(ISNOTHING(Fields!service_end_date.Value), "", " - " & Fields!service_end_date.Value) & "."
Sample 1 with data inserted:
REQUEST #1: That the bill of Some Family Practice attached hereto as Exhibit A is a true and accurate copy of a bill for $933.00 for treatment and services rendered to John A. Doe on 10/16/2006 - 3/5/2010.
Sample 2:
REQUEST #11: That the bill of Another Sports Medicine Center attached hereto as Exhibit C is a true and accurate copy of a bill for $1,210.00 for treatment and services rendered to John A. Doe on 3/9/2007 - 3/27/2007.
So in the above examples the line return is in 2 different spots.
If needed I can create tables and sample data to work with.... Was hoping someone had already worked out a solution 🙂
June 2, 2010 at 8:28 am
I now see the issue, Since the data is in a large text area you dont' really have a whole lot of control over where the breaks happen... Here's a connect issue that you could vote on to help prioritize this in future versions... http://connect.microsoft.com/SQLServer/feedback/details/557661/line-spacing-options-for-ssrs According to the connect item it seems you could play with the lineheight property, but it would only work in HTML rendering which I'm imagining won't work for you as you probably need this to be exported as a pdf or something else...
You could do some math on the strings in your textbox and force a double linebreak (& vbcrlf & vbcrlf & ) based on the length of the Provider and Plaintiff names and then again in the next line. But you'd need to test it very, very well and make certain that if/when your verbiage changes ('cause we all know how often that can happen) that you update you math.
You'd most likely be better off writing this in a custom function that your textbox can call. Pass the request number, providername, paintiffname and dates as parameters to a procedure that returns a properly formed string including the Carriage returns based on the maximum width of your textbox. For more about this, you can read here in BOL.
-Luke.
June 2, 2010 at 8:34 am
I was thinking down that route... was hoping to avoid... I saw some code that you pass in the text, calcs the length and passes back.... Just need to stipulate the line length.
Being a noob at this though, makes the task a bit daunting....
Thanks for the help.
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply