Eliminate Mailto: in Reports

  • Thread starter Thread starter Jen
  • Start date Start date
J

Jen

Access2000 db with hyperlink field for emails. On the
report I don't want to see the Mailto: that is used to
complete the hyperlink to open the sendto window.

I've tried to eliminate the first 7 characters of
mailto:, but then there is a # placed at the beginning
and end of the email address so it doesn't work.
1. What is simplest way to get rid of the mailto: without
having the # signs in the address
2. Sometimes editing the fields cause the display to
include //also.

Any suggestions?
 
Jen,

When you drag a field on to a report from the Field List (or use a wizard to
create the control on the report), the Control's Name will be the same as
the Control Source. However, if you later change the Control Source by
inserting an expression for a calculated field, you must also change the
Control Name.
 
True, that's why I've used queries to try to extract just
the email without the "mailto:" words or # signs in it.
Obviously, this would be a new field which would then be
brought onto the report and not use the original field.

But my question really relates to how to best get the
mailto: not to show up on the report.
 
The easiest way to get rid of the "mailto:" in your data would be to do it
in the query that is going to be the recordsource of your report, as you
haveindicated. Then, use the Mid() function to extract everything after the
"mailto:"

Mid([MyEmailField], 8)

Of course, this will work only for data where the first 7 characters are:
mailto:
 
OK, I see what's happening here (a little research never hurts)...

What you're seeing in the # signs is actually a part of the data when you
use a Hyperlink type field. There is more information in VBA Help using
the search criteria "HyperlinkPart".

I am playing with this now and will post back if a solution is there.
 
The following will work in your query to strip out the #mailto: and the
last # from your hyperlink field:

Mid(,9,Len([email])-9)
 
Back
Top