Hyperlink problem

Y

Yasaf Burshan

Hi,
I'm trying to set up hyplerlink.address value the following vba code

Dim invoicespath As String
Dim invoicesshortpath As String

invoicespath = "c:\management\invoices\"
invoicesshortpath = "invoices\"

MkDir (invoicespath & CompanyName)
Me.Companydirectory.Hyperlink.TextToDisplay = "Click here"
Me.Companydirectory.Hyperlink.Address = "invoicesshortpath & CompanyName
end sub

but everytime I'm running the code I get the following error message:
run-time error '7980':
the hyperlinkaddress or hyperlinksubaddress property is read-only for this
hyperlink

I would appreciate a tip on how to solve this problem.
thanks in advance
 

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