Solved

New line characters in Access memo fields - possible?

Posted on 2004-10-15
5
1,443 Views
Last Modified: 2013-12-24
New line characters in Access memo fields - possible?

I have an Access 2000 database containing some long Memo fields.

Does anyone know if and how it may be possible to embed characters into the Memo field to force a new line (i.e. effectively a new paragraph) when the Memo field is displayed by the FrontPage 2003 Database Results Wizard?

(In a similar way perhaps to the method one can use to insert extra spaces between sentences by embedding a series of   codes).

Thanks for any advice on this.  (I do not want to solve the problem by having several Memo fields replacing the single Memo field).
0
Comment
Question by:Jeeva
  • 3
  • 2
5 Comments
 
LVL 14

Expert Comment

by:hhammash
Comment Utility
Hi,

This is the solution.  You put this code instead of the field name code after putting your DRW to Spooky Diet:

<%=Replace(FP_FieldVal(fp_rs," YourMemoFieldName" ),chr(10)," <br>" )%>

Regards
hhammash
0
 

Author Comment

by:Jeeva
Comment Utility
Thanks very much hhammash.  Excellent.  I accept your answer.  I figured out in the end, even though I didn't have a clue what Spooky Diet meant!

Now for a further 100 points, I imagine that I can use the same technique to replace any character
within the memo field by a break, not just replacing a new line character with a break.
If so, all I need to know is what the chr() value is for any particular character.  

Can you point me to a list somehwere of all the chr() values?  I particularly want the chr() value for the tilde symbol
(wavy line), which is sometimes above the hash symbol or number sign on keyboards.

Thanks if you can help with this as well.
0
 
LVL 14

Accepted Solution

by:
hhammash earned 200 total points
Comment Utility
Hi Jeeva,

Spooky Diet is:
http://www.outfront.net/spooky/adv_drw_diet.htm

The list of chr():
http://www.asciitable.com/

Regards
hhammash
0
 

Author Comment

by:Jeeva
Comment Utility
Thanks very much hhammash!  Jeeva.

For reasons I won't waste time explaining, I decided to represent new line characters in the Access database memo field not with the usual new line character chr(10), but with the ~ tilde (wavy line) symbol, and therefore to use the modified code <%=Replace(FP_FieldVal(fp_rs," YourMemoFieldName" ),chr(126)," <br>" )%> .  This works fine.

Previously I tried doing this with the hash (number sign) symbol #, using chr(35), (rather than with the tilde symbol) and although it did replace # symbols on display with a <br> as required, it had the unfortunate side effect also of changing some other characters within the memo field on display with disastrous results, such as creating hyperlinks within the displayed memo field text, and not showing the pound currency sign as such, but as its html code form.  Are you able to explain why the # sign caused so much havoc please?  Regards.  Jeeva
0
 
LVL 14

Expert Comment

by:hhammash
Comment Utility
Hi,

Maybe because the "#" is used for hyplerlink bookmarks.

Nice approach Jeeva.

hhammash
0

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

Turn A Profile Picture Into A Cartoon Using Photoshop And Illustrator This tutorial will teach you how to make a cartoon style image out of a regular picture. I have tried to keep the tutorial as simple as possible. I used Adobe CS4 for this tuto…
When setting up new project requests for our site, one of the most powerful tools our team has available to use is Axure (http://www.axure.com/). It’s a tool for creating software and web prototypes that can function and interact as if it were the a…
The purpose of this video is to demonstrate how to automatically show related posts at the bottom of a blog post in WordPress. This will be demonstrated using a Windows 8 PC. Plugin “Yet Another Related Posts Plugin” will be used. Go to your…
The purpose of this video is to demonstrate how to Import and export files in WordPress. This will be demonstrated using a Windows 8 PC. Go to your WordPress login page. This will look like the following: mywebsite.com/wp-login.php : Click on Too…

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now