Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 Development Tools
 ASP.NET
 newline inside grid column

Author  Topic 

jhermiz

3564 Posts

Posted - 2005-03-11 : 13:35:15
I do this:


While reader.Read()
strAssigned = strAssigned & CType(reader("Login"), String) & "," & vbNewLine
End While


So I debug and its got the correct string:


Jon,
Joe,
Blah


I want to assign this string to a datagrid column on my grid:


CType(e.Item.FindControl("hlAssignedTo"), HyperLink).Text = f.GetTicketAssignments(CType(CType(e.Item.FindControl("hlTicketID"), HyperLink).Text, Long))


It sets that column but it does not keep the newline...so it comes up as:


Jon, Joe, Blah


I want to keep it with the newline :(

Jon



Keeping the web experience alive -- [url]http://www.web-impulse.com[/url]
Imperfection living for perfection --
[url]http://jhermiz.blogspot.com/[/url]

MichaelP
Jedi Yak

2489 Posts

Posted - 2005-03-11 : 13:58:09
vbnewline <> <BR>

VBNewLine is a CRLF, which is why it looks right in your IDE, but for HTML, you've gotta have your <BR>'s to make it work.

Try this:

While reader.Read()
strAssigned = strAssigned & CType(reader("Login"), String) & ",<BR>" & vbNewLine
End While


Michael

<Yoda>Use the Search page you must. Find the answer you will.</Yoda>
Go to Top of Page

jhermiz

3564 Posts

Posted - 2005-03-11 : 14:00:12
ahh yes you are right forgot its going back to the contents inside the grid which is html :)
shanks plenty

jon



Keeping the web experience alive -- [url]http://www.web-impulse.com[/url]
Imperfection living for perfection --
[url]http://jhermiz.blogspot.com/[/url]
Go to Top of Page
   

- Advertisement -