Solved

Where to learn VB Application for Word on Internet

Posted on 2001-09-14
8
199 Views
Last Modified: 2012-06-27
Hi,I am searching for learning VB Application expecially for MS Word that create hyperlinks on word documents. Can somebody help me ?
0
Comment
Question by:Imelda
8 Comments
 
LVL 49

Accepted Solution

by:
Ryan Chong earned 30 total points
Comment Utility
Hi lmelda,

Some links here:

http://www.learnthat.com/courses/computer/word/

___________________________________

> Insert a hyperlink that goes to another document, file, or Web page:

You can create a hyperlink that goes to an existing file or to a new file. After you've specified a name for the new file, you can choose to open the file for editing immediately or come back to it later. Either way, the file is created for you.

Select the text or drawing object you want to display as the hyperlink, and then click Insert Hyperlink .

(Or press Ctrl+K)


Do one of the following:
To link to an existing file or Web page, click Existing File or Web Page under Link to.

To link to a file that you haven't created yet, click Create New Document under Link to.

Do one of the following:
If you clicked Existing File or Web Page in step 2, locate and select the file you want to link to.

If you clicked Create New Document in step 2, type a name for the new file. You can also specify the path to the new file and choose whether you want to open the new file for editing now or later.

To assign a tip to be displayed when you rest the mouse over the hyperlink, click Screen Tip and then type the text you want. Word uses the path or address of the file as the tip if you do not specify one.


Click OK twice.
Notes

You can quickly create a hyperlink to a Web page without knowing the address. Click Web page to switch to your Web browser, open the World Wide Web page you want, and then switch back to Word.


If you know the address to an existing Web page, you can type it directly into the document. For example, type www.microsoft.com, and Word creates the hyperlink for you.
0
 
LVL 49

Expert Comment

by:Ryan Chong
Comment Utility
Or you want to create a hyperlink programmically?
0
 

Author Comment

by:Imelda
Comment Utility
Yes, I want to create a hyperlink programmically because there are a link plus numbers that increasing on next the link.
0
 
LVL 49

Expert Comment

by:Ryan Chong
Comment Utility
Hi lmelda,

Try this:

Dim Word As Word.Application
Dim Doc As Word.Document


Private Sub Command1_Click()
    Set Word = CreateObject("Word.Application")
    Set Doc = Word.Documents.Add
   
    Word.Selection.TypeText "Hello World"
    Word.Selection.Hyperlinks.Add Anchor:=Selection.Range, Address:="http:\\www.microsoft.com"
    Doc.SaveAs "D:\eee.doc"
    Doc.Close
    Word.Quit
    Set Doc = Nothing
    Set Word = Nothing
End Sub

'Hope will help.
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 49

Expert Comment

by:Ryan Chong
Comment Utility
Hi,

Here is the example from M$ Word's help:

Add Method (Hyperlinks Collection) Example

This example turns the selection into a hyperlink to the Microsoft address on the World Wide Web.

ActiveDocument.Hyperlinks.Add Anchor:=Selection.Range, _
    Address:="http:\\www.microsoft.com"
This example turns the selection into a hyperlink that links to the bookmark named "MyBookMark" in MyFile.doc.

ActiveDocument.Hyperlinks.Add Anchor:=Selection.Range, _
    Address:="C:\My Documents\MyFile.doc", SubAddress:="MyBookMark"
This example turns the first shape in the selection into a hyperlink.

ActiveDocument.Hyperlinks.Add Anchor:=Selection.ShapeRange(1), _
    Address:="http:\\www.microsoft.com"

'Hope will help.
0
 
LVL 1

Expert Comment

by:ncw
Comment Utility
0
 
LVL 49

Expert Comment

by:DanRollins
Comment Utility
Hi Imelda,
It appears that you have forgotten this question. I will ask Community Support to close it unless you finalize it within 7 days. I will ask a Community Support Moderator to:

    Accept ryancys's comment(s) as an answer.

Imelda, if you think your question was not answered at all or if you need help, just post a new comment here; Community Support will help you.  DO NOT accept this comment as an answer.

EXPERTS: If you disagree with that recommendation, please post an explanatory comment.
==========
DanRollins -- EE database cleanup volunteer
0
 
LVL 5

Expert Comment

by:Netminder
Comment Utility
Per recommendation, force-accepted.

Netminder
CS Moderator
0

Featured Post

What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

771 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

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now