How do I get newline characters to work in a gridview cell?
I have the query below for now. It doesn't work, nor do any other newline characters when I reference the column in my gridview. I want the address to be formatted like:
555 Test Dr.
Exam, FL. 55555
Instead I get:
555 Test Dr. \r Exam, FL. 55555
CREATE PROCEDURE dbo.usp_SEL_CL_Net_GetMortgageInformation
@PolicyID AS VARCHAR(15),
@InceptionDate AS SMALLDATETIME,
@PostDate as DATETIME
Select [MortgageeID] AS 'Mortgagee Number',
[Name] AS 'Mortagee Name',
'Address' = CASE WHEN [Address2] = '' THEN
[Address1] + ' \r ' + [City] + ', ' + [State] + '. ' + [ZipCode]
[Address1] + ' \r ' + [Address2] + ' \r ' + [City] + ', ' + [State] + '. ' + [ZipCode]
[LoanID] AS 'Loan Number'
From PlMortgage WITH (NOLOCK)
Where PolicyID = @PolicyID And
InceptionDate = @InceptionDate And
PostDate = @PostDate
Order by MortgageeID