joeshaw123
New member
- Local time
- Today, 23:06
- Joined
- Sep 21, 2012
- Messages
- 3
Hi all,
Found this forums on my search to uncover what I am doing wrong.
I am a complete beginner at using access and VBA, but have been thrust into this position and need to get my head round some basic things!
I'll explain what I need to achieve first:
I have a inventory/stock/sales/purchasing system running on an SQL back end, kindly developed by a former colleague of a colleague. The system itself is running fine, but I have been tasked with tweaking it to add in additional functionality that doesn't affect the running of the existing system.
In short, I have a form named MRP_Inventory, in which you can go through all products that we manufacture/order/sell. I have added in a field called MI_Hyplink, to which a text box named Hyplink is attached, which contains the network path to the PDF file of the technical drawing of the selected component; and obviously the file path changes for each record.
I have used Allen Browne's GoHyperlink (allenbrowne.com/func-GoHyperlink.html[/url]) on the click of a button to treat the file path as a hyperlink.
The code on the button is simply
Private Sub Command57_Click()
Call GoHyperlink(Me.Hyplink)
End Sub
And it has been working! I had only used it on one record and it opened the PDF file up in Adobe Reader as it should. I have since, however, attempted to just fill in other records with their corresponding link, and all I get is error 87: an unexpected error has occurred
Meanwhile, the original one was working fine. I copied the link from the original record into a new one, and it still wouldn't work on the new record. I deleted the link on the original record and replaced it with EXACTLY the same file path and now nothing works at all!
Any ideas? Is there a better way of doing this? I would like to store 2 or 3 different file paths per record as I need to be able to open up a technical drawing, a test method and a manufacturing procedure at the click of an appropriately named button. It has been suggested that I use a shell command, but I haven't the foggiest how to do that.
Any and all help MUCH appreciated, thanks in advance!
Joe
Found this forums on my search to uncover what I am doing wrong.
I am a complete beginner at using access and VBA, but have been thrust into this position and need to get my head round some basic things!
I'll explain what I need to achieve first:
I have a inventory/stock/sales/purchasing system running on an SQL back end, kindly developed by a former colleague of a colleague. The system itself is running fine, but I have been tasked with tweaking it to add in additional functionality that doesn't affect the running of the existing system.
In short, I have a form named MRP_Inventory, in which you can go through all products that we manufacture/order/sell. I have added in a field called MI_Hyplink, to which a text box named Hyplink is attached, which contains the network path to the PDF file of the technical drawing of the selected component; and obviously the file path changes for each record.
I have used Allen Browne's GoHyperlink (allenbrowne.com/func-GoHyperlink.html[/url]) on the click of a button to treat the file path as a hyperlink.
The code on the button is simply
Private Sub Command57_Click()
Call GoHyperlink(Me.Hyplink)
End Sub
And it has been working! I had only used it on one record and it opened the PDF file up in Adobe Reader as it should. I have since, however, attempted to just fill in other records with their corresponding link, and all I get is error 87: an unexpected error has occurred
Meanwhile, the original one was working fine. I copied the link from the original record into a new one, and it still wouldn't work on the new record. I deleted the link on the original record and replaced it with EXACTLY the same file path and now nothing works at all!
Any ideas? Is there a better way of doing this? I would like to store 2 or 3 different file paths per record as I need to be able to open up a technical drawing, a test method and a manufacturing procedure at the click of an appropriately named button. It has been suggested that I use a shell command, but I haven't the foggiest how to do that.
Any and all help MUCH appreciated, thanks in advance!
Joe