#1
  1. No Profile Picture
    Registered User
    ASP Explorer (0 - 99 posts)

    Join Date
    Jan 2013
    Posts
    10
    Rep Power
    0

    display a return as <br/> when displaying text from textbox


    Hi,

    I am sure this is a commen problem but have not fund an easy answer in Google.

    I wish to when I display the text from a text field when an enter has been used replace that enter with a <br/> tag.

    This is what I have so far

    Code:
    <% notes = (rsJobs("notes").Replace("<br/>",char.ConvertFromUtf32(13))) %>
    <% if request.QueryString("edit") = "" then %>
    	<%=notes%>
    <% else %>
    	<% If Request.Form("frmUpdate") <> "" Then %>
    		<textarea id="notes" name="notes" cols="93" rows="5"  class="form"><%=request.Form("notes")%></textarea>
    	<% else %>
    		<textarea id="notes" name="notes" cols="93" rows="5"  class="form"><%=notes%></textarea>
    	<% end if %>
    <% end if %>
    This gives me the following page fault:

    Code:
    Microsoft VBScript runtime 
    
    error '800a01a8' 
    
    Object required: '' 
    
    /administration/jobs-details.asp, line 996
    Any pointers would be greatly appreciated, thanks in advance.
  2. #2
  3. No Profile Picture
    Registered User
    ASP Explorer (0 - 99 posts)

    Join Date
    Jan 2013
    Posts
    10
    Rep Power
    0
    Sorry after all that searching I finally found the answer just after I posted this, typical!

    here is what I used

    Code:
    <%=replace(rsJobs("notes"),vbCrLf,"<BR/>") %>

Similar Threads

  1. Display rich text in textbox & store in SQL Server table
    By holisticsoftwar in forum .NET Development
    Replies: 1
    Last Post: December 10th, 2010, 05:19 PM
  2. TextBox to show display text for a hyperlink
    By jerelp in forum Microsoft Access Help
    Replies: 1
    Last Post: April 21st, 2010, 08:03 PM
  3. display list of text in textbox
    By ajegopinath in forum .NET Development
    Replies: 5
    Last Post: May 10th, 2005, 06:41 AM
  4. Using a checkbox to return text based on another textbox
    By ddennis in forum Microsoft Access Help
    Replies: 1
    Last Post: April 29th, 2005, 04:37 PM
  5. Display long page of text in textbox?
    By DrewPeterson89 in forum .NET Development
    Replies: 1
    Last Post: March 30th, 2005, 06:55 AM

IMN logo majestic logo threadwatch logo seochat tools logo