Question : Concatenating Access rich text memos into a single field

Using Access 2010 I have a rich text field on a form, constructed by concatenating the contents of 20 rich text memo fields in a table (fields named Detail1..Detail20). If the user wants to edit one or more of the fields (all some or none of which can be left blank), they double-click on the field on the form to pop-up a sub-form that allows them to edit each field individually.

The concatenation is currently done in the query which is the data source for the form, very simply by: [Detail1] & [Detal2] & ... & [Detail20], although I can replace this with a VBA function once I'm sure I can get the thing to work as I want.

The size of each individual Detail field is likely to be relatively short (but not fixed) and it's important that different fields or parts of fields can be shown in Bold or Italic. The formatting will be defined by the user and be different for different records. The concatenated result will appear in reports as well as on the form, and is the way the users will almost always view the data.

The problem I have is that the concatenation process puts a hard return between the individual fields, instead of presenting them as one continuous paragraph. Is this inherent in the Rich Text format (i.e. I can't get around it); or will a function let me achieve what I'm looking for?

If the answer is a VBA function, a coding example would be great.

Answer : Concatenating Access rich text memos into a single field

I can't see anything that would "Force" a wrap, like you are getting.
...unless this is a byproduct of using Formatted Memo fields...

Is the Rich (HTML, actually) text formatting absolutely needed?
(In other words, do you really need to format individual words?)

Because if plain text works, you can format the control that displays the entire concatenated string (txtCitation?) in one style...

;-)

JeffCoachman
Random Solutions  
 
programming4us programming4us