Solved

MS Access 2010 How can I open a Word document from within Access?

Posted on 2012-04-09
7
685 Views
Last Modified: 2012-04-09
I'd like to be able to hyperlink to a Word document by clicking a button on an Access 2010 form.   I can't seem to find a macro to do this, and I'm not familiar enough with VBA (yet) to do it. (I just starting to learn VBA.)  

I know I can create a hyperlink from a field within a table, but I'd like to hyperlink to the document directly from the form.

Can you help me with this?   Thanks.  WallyTee
0
Comment
Question by:WallyTee
7 Comments
 
LVL 12

Assisted Solution

by:xmlmagician
xmlmagician earned 100 total points
ID: 37824321
0
 
LVL 39

Assisted Solution

by:als315
als315 earned 100 total points
ID: 37824326
Test this sample:
DBHyperlink.accdb
0
 
LVL 47

Accepted Solution

by:
Dale Fye (Access MVP) earned 100 total points
ID: 37824363
In the click event of a button, use:

application.followhyperlink "C:\foldername\filename.doc"
0
Use Case: Protecting a Hybrid Cloud Infrastructure

Microsoft Azure is rapidly becoming the norm in dynamic IT environments. This document describes the challenges that organizations face when protecting data in a hybrid cloud IT environment and presents a use case to demonstrate how Acronis Backup protects all data.

 
LVL 21

Assisted Solution

by:Boyd (HiTechCoach) Trimmell, Microsoft Access MVP
Boyd (HiTechCoach) Trimmell, Microsoft Access MVP earned 100 total points
ID: 37824470
See:    Hyperlinks: warnings, special characters, errors

I prefer to use the ShellExec API to avoid the issue with Hyperlinks.  Here is an example I created: Document Links
0
 

Author Comment

by:WallyTee
ID: 37824663
Thanks to all.  I'll give your suggestions a shot and see how far I can get.   WallyTee
0
 
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 37824981
<No Points wanted>

<I'd like to be able to hyperlink to a Word document by clicking a button on an Access 2010 form.   I can't seem to find a macro to do this, and I'm not familiar enough with VBA (yet) to do it. (I just starting to learn VBA.)  >
A Macro cannot "create" a hyperlink, nor can it be easily made to Follow one.
0
 

Author Closing Comment

by:WallyTee
ID: 37825118
Thanks again to all.   You can close this one out.   WallyTee
0

Featured Post

Enterprise Mobility and BYOD For Dummies

Like “For Dummies” books, you can read this in whatever order you choose and learn about mobility and BYOD; and how to put a competitive mobile infrastructure in place. Developed for SMBs and large enterprises alike, you will find helpful use cases, planning, and implementation.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
Outlook Free & Paid Tools
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.
Learn how to create and modify your own paragraph styles in Microsoft Word. This can be helpful when wanting to make consistently referenced styles throughout a document or template.

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question