![]() |
|
#1
|
|||
|
|||
|
Hi all,
I am wondering how to go to a bookmark in Word when its macro is ran from Excel. This is what I have in Excel at the moment: Code:
Dim wrdApp As Word.Application
Dim wrdDoc As Word.Document
Dim i As Integer
Set wrdApp = CreateObject("Word.Application")
wrdApp.Visible = True
Set wrdDoc = wrdApp.Documents.Open(directory)
With wrdDoc
If .Bookmarks.Exists("g") Then
MsgBox "yes"
wrdDoc.GoTo What:=wdGoToBookmark, Name:="g"
Else
MsgBox "Not Found"
End If
Thank you, Matt |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Can this be fix in excel or should I go to word | lostsoul62 | Excel | 1 | 04-18-2012 01:00 AM |
| From Excel to Word? | lostsoul62 | Word | 1 | 03-19-2012 06:20 PM |
Open Word w Excel & fill Word textboxes w info from Excel fields runtime error 4248
|
Joe Patrick | Word VBA | 2 | 01-30-2012 07:23 AM |
Word to Excel
|
rynman | Office | 5 | 04-19-2009 06:50 AM |
Excel to Word
|
retrospect1984 | Excel | 1 | 02-18-2009 06:41 AM |