[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Issue with Hyperlink 'Text to Display' containing # Symbol in Access

Posted on 2009-02-13
8
Medium Priority
?
459 Views
Last Modified: 2013-11-28
I have a Access front end that displays a hyperlink retreived from a SQL server. The problem is that one of the 'text to display' part numbers has a # symbol in it and that causes it truncate or not connect to the proper hyperlink in the back ground. Is there a way to encapsulate this # symbol so it wont affect the hyperlink?
0
Comment
Question by:filtrationproducts
  • 4
  • 2
  • 2
8 Comments
 
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 23640141
filtrationproducts,

Well, without seeing the string, all I can suggest is that you replace the  "#" with an empty string (""):

    YourHyperlinkField=Replace(YourHyperlinkField,"#","")

Can you paste the string here for us to examine?

JeffCoachman
0
 
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 23640149
Or wrap in single quotes

    YourHyperlinkField=Replace(YourHyperlinkField,"#","'#'")
0
 
LVL 13

Expert Comment

by:ioane
ID: 23642201
filtrationproducts,

I don't tihink there is anyway to include the # in any part of a hyperlink.

boag2000 is right about needing to replace the # but you only want to replace the first instance so:
YourHyperlinkField=Replace(YourHyperlinkField,"#","",1)

Note: this will only work with situations where there is a hash (#) in the display text.

You may want to count the number of #'s first to determine if there are more than 3 etc.
0
Granular recovery for Microsoft Exchange

With Veeam Explorer for Microsoft Exchange you can choose the Exchange Servers and restore points you’re interested in, and Veeam Explorer will present the contents of those mailbox stores for browsing, searching and exporting.

 
LVL 1

Author Comment

by:filtrationproducts
ID: 23650529
The hyperlink is created from a query. Here is what the problem hyperlink data looks like.

TORO # 74-3570#J:\elements\documentation\TORO # 74-3570.SLDDRW#

0
 
LVL 1

Author Comment

by:filtrationproducts
ID: 23650567
I tried putting the code below in the query for the "display text" field. But its not working.
Replace("#","")

How can I configure the 1 column in the query to remove the # symbols.
temp.JPG
0
 
LVL 1

Author Comment

by:filtrationproducts
ID: 23650592
I changed ID to display only the word "drawing" but the # symbol in the hyperlink itself causes it to error. I dont know if this is going to be possible.

Is there anyway to make a hyperlink containing a # symbol work in Access. I cant remove the # because its the actual filename and this cannot be changed.
0
 
LVL 13

Accepted Solution

by:
ioane earned 500 total points
ID: 23653288
Hi filtrationproducts,

As I stated in my comment above, for the replace function to work you need to only replace the first instance of the #.
i.e. Replace("#","",1)

If you have a # in your actual filename then you probably need to do away with the hyperlink altogether and just store the filename as a text string.

You can then emulate a hyperlink by using the OnClick event and the FollowHyperlink function.
i.e. FollowHyperlink("J:\elements\documentation\TORO # 74-3570.SLDDRW",,True)
0
 
LVL 1

Author Comment

by:filtrationproducts
ID: 23654126
Tramtrak: I will try that now
0

Featured Post

Granular recovery for Microsoft Exchange

With Veeam Explorer for Microsoft Exchange you can choose the Exchange Servers and restore points you’re interested in, and Veeam Explorer will present the contents of those mailbox stores for browsing, searching and exporting.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

We live in a world of interfaces like the one in the title picture. VBA also allows to use interfaces which offers a lot of possibilities. This article describes how to use interfaces in VBA and how to work around their bugs.
If you’re using QODBC to update QuickBooks data from Microsoft® Access but Access is not showing the updated data, you could have set up QODBC incorrectly.
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…
Look below the covers at a subform control , and the form that is inside it. Explore properties and see how easy it is to aggregate, get statistics, and synchronize results for your data. A Microsoft Access subform is used to show relevant calcul…
Suggested Courses

834 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