Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

VBA for MS word [closed]

Tags:

ms-word

vba

There are a lot of free sources to learn about the object model of MS Excel, but I failed to find any comprehensive source for a similar source for MS Word.

Can You suggest a free and comprehensive source for the same?

like image 568
Vaibhav Garg Avatar asked Oct 16 '08 03:10

Vaibhav Garg


2 Answers

I recently learned the Word Object Model and I found the following pages most helpful. I think that as long as you understand the Word Application (from a user perspective), all you need to do is flesh out your understanding of Word.Range and eventually Word Story Types. And as the other posters have suggested, the Object Browser in Word's Visual Basic Editor is very convenient for browsing the available properties and methods for any particular object.

Entry point for all Word VBA. Browse by method, object, collection, etc.:

  • Microsoft Word Visual Basic Reference

Helpful pages specifically about using Word's Ranges:

  • Working with Ranges

  • Modifying a portion of a document

  • Selection object

  • Assigning Ranges

An introduction to Word's Story Types:

  • Behind the Curtain: Stories in Word
like image 133
Carl G Avatar answered Sep 19 '22 09:09

Carl G


In the VBA editor, if you hit F2, there's an object browser that is a pretty handy reference. You can also filter it for Word-specific objects.

like image 27
yalestar Avatar answered Sep 19 '22 09:09

yalestar