Truncated Hyperlink

mike p

New member
Local time
Today, 08:58
Joined
Apr 1, 2011
Messages
8
auto storage

I have a hyperlink field in my database.

When i drag and drop a *.pdf file onto that field.

I need code that will additionaly rename the file and place it into a designated directory on my intranet.

The leftover hyperlink wants to connect to the new file.
 
Re: auto storage

This is how far I've got.

Dim Doc_Name As String
Dim History_Folder As String

History_Folder = "G:\New G Drive\Data\Change_Request_Database\File_storage"
Doc_Name = "(Part #) & (Change request #) & (Date) & (MOT1)"
FileName = RDB_Create_PDF(History_Folder & "\" & Doc_Name & ".pdf", True, True)

This part isn't working.
 
Is there a setting that will stop the truncation of the first portion of a local hyperlink (my own drive)?

when adding a hyperlink into my database leading to a file on my own drive it reads..

..\temp.pdf

I need it to read..

C:\temp\temp.pdf
 
Last edited:
Not too sure about this as I haven't played with hyperlinks for a while but you could save the hyperlink as text and then change it back on click

Suck it 'n' C

Regards
Smalltime
 
Re: auto storage

I'm down to my last line where i reload the new hyperlink into the old field and something isn't working there.

Dim db As Database
Dim rs As Recordset

Dim Doc_Name As String
Dim PartNmber As String
Dim ChangeRequestNumber As String
'Dim Dte As String
Dim Hyper_MOT1 As String


PartNmber = Forms![Change Request Form]![Part #]
ChangeRequestNumber = Forms![Change Request Form]![Change request #]

Hyper_MOT1 = HyperlinkPart(Forms![Change Request Form]![MOT1], acAddress)
Doc_Name = PartNmber & "MOT" & ChangeRequestNumber & ".pdf"

Name Hyper_MOT1 As "G:\G Drive\Data\Access Databases\Change_Request_Database\File_storage\" & Doc_Name
Me.MOT1.HyperlinkAddress = "G:\G Drive\Data\Access Databases\Change_Request_Database\File_storage\" & Doc_Name
 
I found out about the trucation. In the feild it assumes any portion of a hyperlink when the file is in the same drive as the database.

I'm down to my last line where i reload the new hyperlink into the old field and something isn't working there.

Dim db As Database
Dim rs As Recordset

Dim Doc_Name As String
Dim PartNmber As String
Dim ChangeRequestNumber As String
'Dim Dte As String
Dim Hyper_MOT1 As String


PartNmber = Forms![Change Request Form]![Part #]
ChangeRequestNumber = Forms![Change Request Form]![Change request #]

Hyper_MOT1 = HyperlinkPart(Forms![Change Request Form]![MOT1], acAddress)
Doc_Name = PartNmber & "MOT" & ChangeRequestNumber & ".pdf"

Name Hyper_MOT1 As "G:\G Drive\Data\Access Databases\Change_Request_Database\File_storage\" & Doc_Name
Me.MOT1.HyperlinkAddress = "G:\G Drive\Data\Access Databases\Change_Request_Database\File_storage\" & Doc_Name
 
Mike p

When I need the full document path this is what I do.... Without opening the document, right click on it and open properties. You'll see the file location under the General tab. Trying copying and pasting it into your database. This works for me.

Wanda
 

Users who are viewing this thread

Back
Top Bottom