Hi Waterman:
I have a solution.
My user has to open and Insurance Application form from an
Access form, i didn't use Hyperlink as didn't work with a
button so I have a option group where one of them is:
Insurance Application Form, and a button Named "Open"
In Module i have created a public function for opening
Word Documents:
Public Function OpenWordFile(pstrpath As String)
Dim pobjWord As Word.Document
Set pobjWord = GetObject(pstrpath)
pobjWord.Application.Visible = True
Set pobjWord = Nothing
End Function
and I call this function under the option as below (on
command button click-Event)
.......
dim pstrpath as string
.....
Case 6
'Opens Insurance application form
pstrpath = "G:\Database\ExhIns_2.doc"
Call OpenWordFile(pstrpath)
......
It works fine for me until now. IF somebody has anyother
solution would be great.
Thanks,
Marsela
>-----Original Message-----
>I am creating a simple HR application and need to assign
a value to the
>hyperlink address property of a command button using VBA
code so that I can
>give the user a link to a job description in Word. I can
set the value but
>when I click the button it gives a message that the file
cannot be found;
>however, it is where it is supposed to be. I have paused
the code to see
>what the hyperlink value is beig set to and it is the
correct address but it
>displays with the # symbol at each end. I think the #
symbols are causing
>the problem. How do I get rid of them.
>
>Thanks for the help
>.
>
|