By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
425,460 Members | 2,215 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 425,460 IT Pros & Developers. It's quick & easy.

Sub or Function not defined

P: n/a
Hello all,
I have an Access form, wherein the user can put in some data. These data
will be used in a Word document. All goes well except for the line indent
.... I get the error message "Sub or Function not defined"
Here is the code

Dim appWD As Object
Set appWD = CreateObject("Word.Application")
appWD.Visible = True
appWD.Documents.Add
With appWD
Set myDoc = .Documents.Add

' this is the problem line
ActiveDocument.Paragraphs(1).LeftIndent =
CentimetersToPoints(20)
' I also tried :
ActiveDocument.Paragraphs(1).LeftIndent = InchesToPoints(20)
'but that doesn't work either ....

Any help would be very much appreciated ....
Thanks !
Ronny Sigo


Nov 12 '05 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.