I have a database which users can view files from. I simply set the hyperlink address of a command button to the relevant file path and when they click the button it opens the file.
Public Function OpenDocument(strDocPath As String)
Dim Fl As Long
Fl = Shell("RUNDLL32.EXE URL.DLL,FileProtocolHandler " & strDocPath, vbNormalFocus)
End Function
FollowHyperlink will open a file using the default application for registered extensions. You can open Websites, email (using mailto, files, directories and so on.
thanks RoyVidar & thanks all of u.
i have tried the link given by RoyVidar and it works very well.
also i will try the followhyperlink.
thanks for your reply.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.