Thread: Macro errors
View Single Post
 
Old 09-15-2012, 08:40 PM
macropod's Avatar
macropod macropod is online now Windows 7 64bit Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,467
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

As you will see from the code I posted, there can be multiple 'Call OpenDoc' entries - each of subs except the last has one. That is not the problem. However, a code module can only have one sub named Sub OpenDoc. What concerns me about the code snippet you posted, though, is that the first code block doesn't have a sub name; it should have a first line like Sub MMM(). If that is lacking, you can run that sub and it may cause the errors you're experiencing.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote