View Single Post
 
Old 04-01-2021, 04:29 PM
mbcohn mbcohn is offline Windows 10 Office 2016
Advanced Beginner
 
Join Date: Jan 2021
Posts: 32
mbcohn is on a distinguished road
Default

So, I see that the slashes are missing from that code I just entered above. I added them back, and am now getting the error here (invalid procedure call or argument).


Code:
'Store Information About Word File
   myPath = ActiveDocument.FullName
   CurrentFolder = ActiveDocument.Path & "\"
   FileName = Mid(myPath, InStrRev(myPath, "\") + 1, _
    InStrRev(myPath, ".") - InStrRev(myPath, "\") - 1)
No idea what's going on. Could the code somehow be changing when it runs?
Reply With Quote