#1
|
|||
|
|||
Problem in macro
Hello,
I have made this macro : Code:
Sub JUD_OMZET_DOC2() Dim strDocName As String Dim strDocPath As String On Error Resume Next strDocPath = ActiveDocument.Path & Application.PathSeparator strDocName = ActiveDocument.Name intPos = InStrRev(strDocName, ".") If intPos <> 0 Then strDocName = Left(strDocName, intPos - 1) End If strDocName = strDocName & ".DOC" ActiveDocument.Saved = False ActiveDocument.SaveAs2 FileName:=strDocPath & strDocName, FileFormat:=wdFormatDocument97, _ LockComments:=False, Password:="", AddToRecentFiles:=True, WritePassword _ :="", ReadOnlyRecommended:=False, EmbedTrueTypeFonts:=False, _ SaveNativePictureFormat:=False, SaveFormsData:=False, SaveAsAOCELetter:= _ False End Sub On my PC with Office 2013, it's working very well. But on another PC (Windows 8) on which Office 2013 is recently installed (downloaded version), a dialog box is always shown on which I have to confirm the save. Why is it working fine on my PC (no dialog box to confirm), and why does the dialog box appear on the other PC? Thanks. Last edited by macropod; 02-03-2015 at 04:33 PM. Reason: Added code tags & formatting |
#2
|
||||
|
||||
Perhaps because another document of the name you're trying to save to is already open on the other PC.
PS: When posting code, please use the code tags, indicated by the # button on the posting menu.
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
Thread Tools | |
Display Modes | |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Macro problem | Ulodesk | Outlook | 7 | 08-26-2014 11:18 AM |
EXCEL macro problem please help! | ryguy551 | Excel Programming | 2 | 05-22-2014 03:58 PM |
Problem with macro | MS baby | Excel Programming | 4 | 03-31-2014 02:47 PM |
Problem with macro | tmill29 | Excel Programming | 1 | 06-08-2013 09:59 AM |
Another simple macro problem | Ulodesk | Word VBA | 1 | 06-08-2012 06:24 PM |