Dot Leaders in Report

G

Guest

I am attempting to make a simple phone list report using dot leaders between
the persons name and phone number and can't get the columns to line up. I
have tried using article 210356 from the website, but it doesn't seem to work
due to the varied lengths of names.

Any suggestions would be appreciated.

Vince
 
P

PC Datasheet

Base your report on a query. Put the following expression in a blank field
in the query:
PersonName:[Lastname] & ", " & [FirstName] & IIF(IsNull([MI]),""," " & [MI])

Then put this expression in another blank field in the query:
PhoneListing:[PersonName] & Left("
.......................",20-Len([PersonName])) & " " & [PhoneNum]

Notes:
1. " ......................" Begins with a space. No space at end. Must
contain enough dots so the shortest name of a person will display enough
dots. You'll have to experiment a bit with how many dots to use here.
2. 20 - One less than where you want the phone number to start.

Example listing from above:
Smith, John ........................................ 666-3434
Alexander, Matthew R ...................... 555-1212
 
S

Stephen Lebans

See:
http://www.lebans.com/leaderdots.htm

LeaderDots.zip is a database containing functions to allow a user to
fill in the space between 2 controls with leading dots.

NEW - Feb. 15/2000 Ver 2.0. You can now use the Alignment property for
both the Left and Right Columns. Fix formatting Bug on long lines.

New Jan. 02/2001 A "real" Phone Book Report based on a modified version
of LeaderDots. Created by Chad Edie. Really Sharp!
TelephonePhoneBook.zip

Version 1.0 includes 2 functions. One for Single output lines and one
for Multiple output lines

Produce leading dots between 2 strings.
Like you see on Menu's etc. For example:
Hamburger..........$3.99
HotDog...............$2.99
The Singleline version supports Left, Right
and Center Alignments for the
Left Column. The MultiLine version only supports Left Alignment.


--

HTH
Stephen Lebans
http://www.lebans.com
Access Code, Tips and Tricks
Please respond only to the newsgroups so everyone can benefit.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top