Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Text Field Paragraph Formatting: Impossible?

Status
Not open for further replies.

RobTsintas

Technical User
May 17, 2001
58
GB
I am creating a report which will produce the insert for an official booklet, so the layout is very important.

I want to alter the paragraph formatting for the text field in the detail section, so that, where the text wraps on to a second line for a particular record, the second line is indented from the first. (CanGrow is set to yes so that wrapping works).

So, I need to either:

Find a way to alter paragraph formatting for a text field.

or,

Find a way to link two text fields so that the text from one overflows into the next (I could then put the second one indented below the first).

Anyone know something I don't??
(Thanks in advance)
 
Access doesn't do paragraph formatting like you require, but you could do some stuff to link the text fields. What makes it difficult is the font you are using. If you are using a font that isn't MonoSpaced (IE: just about anything but Courier) then the number of characters you can fit on a line is varied and you'd have to figure out how many characters to fill the line using the data you have combined with the font. This is NOT fun to do, let me tell ya.. I've had to do similar stuff in the past. If it's possible to use Courier or Courier New as your font then this problem becomes very easy to surmount.

To give you the basic idea if the font is Courier, make a control that will be your first line and run the report. Count how many characters the first line yields. So for illustrations sake, let's say you have a 200 character field in a control called [MyData] and 50 characters appear on the first indented line. Now make another textbox (the second line) and make it's control source:

=Right([MyData], 150)

That will make the final 150 characters appear in the second text box which you can then do your indenting and formatting with the CanGrow property set.

HTH Joe Miller
joe.miller@flotech.net
 
I thought this might be a non-starter; I definately can't use a fixed-width font.

It's a shame there's no paragraph formatting, you'd have thought Microsoft would have included something so fundamental.

Thanks for trying anyway.
 
You need to remember that Access is a database tool, not a word processing tool. It's really not an oversight on their part but more sticking to an industry standard. You might look into automating with Word, you can send data to word to be formatted and stuff. Don't know how that would work for you, but it's worth investigation.

Joe Miller
joe.miller@flotech.net
 

We are already going to have to use the export to word method while I try to get the report formatting to an acceptable level.

However, some fields on the page (such as page numbers in the page footer) don't always appear in the same position in Word.
Could this be associated with page settings/margins?

Also, certain sections are separated with a simple horizontal line in the report, but these don't appear in the exported word documents, which is a pain.
 
I really don't know much about the automation with word so i would try to find some tutorials on it. Sorry! :-(

Joe Joe Miller
joe.miller@flotech.net
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top