Dealing with document chunks

If you know the start and end position of the text you want, you can simply get at it using the Mid function, which has the general form:

Mid(start, length)

For example:

MsgBox ActiveDocument.Text.Mid(0, 10) ' returns the first 10 characters of the document

i = ActiveDocument.Text.Count

MsgBox ActiveDocument.Text.Mid(0, i) ' returns all the characters of the document

MsgBox ActiveDocument.Text.Mid(10, 20) ' returns 20 characters starting at position 10