Բաց թողնել հիմնական բովանդակությունը

Ինչպե՞ս Word- ում .doc ֆորմատի ֆայլերը խմբաքանակով փոխարկել .docx- ի:

Ենթադրելով, որ դուք ստացել եք 97-2003 ձևաչափի Word փաստաթղթեր, ինչպե՞ս կարող եք խմբաքանակով միանգամից վերափոխել այս .doc ձևաչափի բոլոր փաստաթղթերը: docx ձևաչափի: Այս հոդվածը ձեզ ցույց կտա այս խնդրի լուծման երկու մեթոդ:

Փոխանակել .doc ձևաչափի ֆայլերը .docx- ի ՝ VBA կոդով
Խմբաքանակը .doc ձևաչափի ֆայլերը վերափոխում է .docx- ի `Kutools- ի համար Word- ի համար


Փոխանակել .doc ձևաչափի ֆայլերը .docx- ի ՝ VBA կոդով

Այս բաժինը պատրաստվում է ցույց տալ ձեզ VBA կոդը ՝ որոշակի պանակում միանգամից .docx փաստաթղթերի փոխակերպելու համար .doc ձևաչափի բոլոր փաստաթղթերը: Խնդրում եմ արեք հետևյալ կերպ.

1. Խնդրում ենք նշված պանակում հավաքել .doc ձևաչափի բոլոր փաստաթղթերը, որոնք կփոխարկեք:

2. Սեղմեք ալտ + F11 բանալին բացելու համար Microsoft Visual Basic հավելվածների համար պատուհան.

3. Պատուհանում կտտացրեք Տեղադրել > Մոդուլներ, Դրանից հետո VBA կոդի ներքո պատճենեք Մոդուլի պատուհանում:

VBA կոդ. Խմբաքանակը .doc ձևաչափի բոլոր փաստաթղթերը որոշակի թղթապանակում վերափոխում է .docx- ի

Sub ConvertDocToDocx()
'Updated by ExtendOffice 20181128
    Dim xDlg As FileDialog
    Dim xFolder As Variant
    Dim xFileName As String
    Application.ScreenUpdating = False
    Set xDlg = Application.FileDialog(msoFileDialogFolderPicker)
    If xDlg.Show <> -1 Then Exit Sub
    xFolder = xDlg.SelectedItems(1) + "\"
    xFileName = Dir(xFolder & "*.doc", vbNormal)
    While xFileName <> ""
        Documents.Open FileName:=xFolder & xFileName, _
            ConfirmConversions:=False, ReadOnly:=False, AddToRecentFiles:=False, _
            PasswordDocument:="", PasswordTemplate:="", Revert:=False, _
            WritePasswordDocument:="", WritePasswordTemplate:="", Format:= _
            wdOpenFormatAuto, XMLTransform:=""
        ActiveDocument.SaveAs xFolder & Replace(xFileName, "doc", "docx"), wdFormatDocumentDefault
        ActiveDocument.Close
        xFileName = Dir()
    Wend
    Application.ScreenUpdating = True
End Sub

4. Սեղմեք F5 ծածկագիրը գործելու համար: Բացման մեջ Թերթել պատուհանը, ընտրեք պանակը, որը պարունակում է .doc ձևաչափի փաստաթղթերը և կտտացրեք OK, Տեսեք,

Այնուհետև .doc ձևաչափի բոլոր փաստաթղթերը անմիջապես վերափոխվում են .docx փաստաթղթերի, ինչպես ցույց է տրված նկարում:


Խմբաքանակը .doc ձևաչափի ֆայլերը վերափոխում է .docx- ի `Kutools- ի համար Word- ի համար

Այս բաժնում օգտակար կոմունալ առաջարկվում է: Հետ Doc / Docx օգտակարությունը Kutools բառի համար, Դուք կարող եք հեշտությամբ փոխել թղթապանակի բոլոր .doc ձևաչափի փաստաթղթերը .docx փաստաթղթերի: Խնդրում ենք փորձել հետևյալ կերպ.

Kutools բառի համար ՝ ավելի քան 100 հարմար բառերի հավելումներով, անվճար փորձելու առանց սահմանափակման 60 օր.

1. Խնդրում ենք հավաքել .doc ձևաչափի բոլոր փաստաթղթերը նշված պանակում, ապա կտտացնել Kutools Plus > Doc / Docx, Տեսեք,

2. Մեջ Փաստաթղթի ձևաչափի փոխարկիչ երկխոսության տուփ, դուք պետք է անեք հետևյալը.

2.1) Ընտրեք պանակը, որը պարունակում է .doc ձևաչափի փաստաթղթեր Աղբյուրի ֆայլի պանակ Բաժին;
2.2) Ընտրեք Փոխակերպել doc- ը docx- ի - ից Ձևաչափի փոխարկում բացվող ցուցակ;
2.3) Լռելյայնորեն, Նպատակակետի ուղին նույնն է, ինչ աղբյուրը վանդակը ստուգված է: Եթե ​​ուզում եք բոլոր փոխարկված .docx փաստաթղթերը տեղադրել նույն պանակում, պարզապես այս տարբերակը ընտրված պահեք.
Եթե ​​ցանկանում եք առանձնացնել .docx փաստաթղթերը և աղբյուրի .doc փաստաթղթերը, ապա ընտրեք ընտրությունը Նպատակակետի ուղին նույնն է, ինչ աղբյուրը տուփը և ընտրեք նոր պանակ ՝ .docx փաստաթղթերը պահելու համար Պահպանել տուփ;
2.4) Կտտացրեք այն սկիզբ կոճակ Տեսեք,

3. Դրանից հետո բացվում է երկխոսության տուփ ՝ ձեզ ասելու համար, թե քանի փաստաթուղթ է հաջողությամբ փոխարկվել, կտտացրեք այն OK կոճակը և փակել այն Փաստաթղթի ձևաչափի փոխարկիչ պատուհան.

Այժմ .doc ձևաչափի բոլոր փաստաթղթերը փոխարկվում են .docx ֆայլերի: Տեսեք,

Եթե ​​ցանկանում եք անվճար օգտվել այս օգտակար ծառայությունից, գնացեք այստեղ անվճար ներբեռնել ծրագրաշարը նախ և ապա անցեք գործողությունը կիրառելու համար ՝ համաձայն վերը նշված քայլերի:


Գրասենյակի արտադրողականության լավագույն գործիքները

Outlook- ի համար նախատեսված գործիքներ - Ավելի քան 100 հզոր գործառույթ՝ ձեր Outlook-ը լիցքավորելու համար

🤖 AI Փոստի օգնական: Ակնթարթային պրոֆեսիոնալ նամակներ AI մոգությամբ. մեկ սեղմումով հանճարեղ պատասխաններ, կատարյալ հնչերանգներ, բազմալեզու վարպետություն: Փոխակերպեք էլ. փոստը առանց ջանքերի: ...

📧 Email ավտոմատացում: Գրասենյակից դուրս (հասանելի է POP-ի և IMAP-ի համար)  /  Ժամանակացույց ուղարկել նամակներ  /  Ավտոմատ CC/BCC էլփոստ ուղարկելիս կանոններով  /  Ավտոմատ փոխանցում (Ընդլայնված կանոններ)   /  Ավտոմատ ավելացնել ողջույնները   /  Ավտոմատ կերպով բաժանել բազմասերիստացող նամակները առանձին հաղորդագրությունների ...

📨 էլեկտրոնային կառավարման: Հեշտությամբ հիշեք նամակները  /  Արգելափակել խարդախության նամակները ըստ առարկաների և այլոց  /  Deleteնջել կրկնօրինակ նամակները  /  Ընդլայնված որոնում  /  Համախմբել Թղթապանակները ...

📁 Հավելվածներ ProԽմբաքանակի պահպանում  /  Խմբաքանակի անջատում  /  Խմբաքանակային կոմպրես  /  Auto Save- ը   /  Ավտոմատ անջատում  /  Ավտոմատ սեղմում ...

🌟 Ինտերֆեյս Magic: 😊Ավելի գեղեցիկ և զով էմոջիներ   /  Բարձրացրեք ձեր Outlook-ի արտադրողականությունը ներդիրներով դիտումների միջոցով  /  Նվազագույնի հասցնել Outlook-ը փակելու փոխարեն ...

???? Մեկ սեղմումով Հրաշքներ: Պատասխանել բոլորին մուտքային հավելվածներով  /   Հակաֆիշինգի էլ. նամակներ  /  🕘Ցուցադրել ուղարկողի ժամային գոտին ...

👩🏼‍🤝‍👩🏻 Կոնտակտներ և օրացույց: Խմբաքանակի ավելացրեք կոնտակտներ ընտրված էլ  /  Կոնտակտային խումբը բաժանեք առանձին խմբերի  /  Հեռացնել ծննդյան հիշեցումները ...

Over 100 Նկարագրություն Սպասեք ձեր հետազոտությանը: Սեղմեք այստեղ՝ ավելին բացահայտելու համար:

 

 

Comments (14)
No ratings yet. Be the first to rate!
This comment was minimized by the moderator on the site
Dobrý den,
já bych potřeboval, ale VBA script který by fungoval včetně podsložek. Umíte někdo prosím upravit i tento skript? Děkuji.

ENG:
Good day,
I would need a VBA script that would work including subfolders. Can someone please edit this script as well? Thank you.
This comment was minimized by the moderator on the site
Hi Daniel Beneš,
To include subfolders, please try the following VBA code.
After adding the code, go to the Tools tab, click References, in the opening References - Project dialog box, check the Microsoft Scripting Runtime box, and then click the OK button to save the changes. See the following screenshot:
https://www.extendoffice.com/images/stories/comments/comment-picture-zxm/check-scripting_runtime.png
After that, press the F5 key to run the code.

Sub ConvertDocToDocx()
'Updated by ExtendOffice 20221124
  Dim xDlg As FileDialog
  Dim xFldPath As Variant
  Dim xFileName As String
  On Error Resume Next
  Application.ScreenUpdating = False
  Set xDlg = Application.FileDialog(msoFileDialogFolderPicker)
  If xDlg.Show <> -1 Then Exit Sub
  xFldPath = xDlg.SelectedItems(1) + "\"
  Call ListAllFiles(xFldPath)
  Application.ScreenUpdating = True
End Sub

Function ListAllFiles(FldPath)
  Dim xFSO As FileSystemObject
  Dim xFolder As Folder
  Dim xSubFolder As Folder
  Dim xNewName As String
  On Error Resume Next
  xFileName = Dir(FldPath & "*.doc", vbNormal)
  While xFileName <> ""
    xNewName = VBA.Left$(xFileName, VBA.InStrRev(xFileName, "doc") - 1) & "docx"
    Documents.Open FileName:=FldPath & xFileName, _
        ConfirmConversions:=False, ReadOnly:=False, AddToRecentFiles:=False, _
        PasswordDocument:="", PasswordTemplate:="", Revert:=False, _
        WritePasswordDocument:="", WritePasswordTemplate:="", Format:= _
        wdOpenFormatAuto, XMLTransform:=""
    ActiveDocument.SaveAs FldPath & xNewName, wdFormatDocumentDefault
    ActiveDocument.Close
    xFileName = Dir()
  Wend
  Set xFSO = CreateObject("Scripting.FileSystemObject")
  Set xFolder = xFSO.GetFolder(FldPath)
  For Each xSubFolder In xFolder.SubFolders
    Call ListAllFiles(xSubFolder.Path + "\")
  Next
  Set xFSO = Nothing
  Set xFolder = Nothing
End Function
This comment was minimized by the moderator on the site
Nice tool but I got the problem, that I can't convert DOC files (written in capitals!) into docx files.
It works with doc files.
This comment was minimized by the moderator on the site
Hi,
The following code can help to convert both doc. and DOC. files into docx files. Please give it a try. Thanks for your feedback.

Sub ConvertDocToDocx()
'Updated by ExtendOffice 20220506
    Dim xDlg As FileDialog
    Dim xFolder As Variant
    Dim xFileName As String
    Application.ScreenUpdating = False
    Set xDlg = Application.FileDialog(msoFileDialogFolderPicker)
    If xDlg.Show <> -1 Then Exit Sub
    xFolder = xDlg.SelectedItems(1) + "\"
    xFileName = Dir(xFolder & "*.doc", vbNormal)
    While xFileName <> ""
        Documents.Open FileName:=xFolder & xFileName, _
            ConfirmConversions:=False, ReadOnly:=False, AddToRecentFiles:=False, _
            PasswordDocument:="", PasswordTemplate:="", Revert:=False, _
            WritePasswordDocument:="", WritePasswordTemplate:="", Format:= _
            wdOpenFormatAuto, XMLTransform:=""
        ActiveDocument.SaveAs xFolder & Replace(VBA.LCase(xFileName), "doc", "docx"), wdFormatDocumentDefault
        ActiveDocument.Close
        xFileName = Dir()
    Wend
    Application.ScreenUpdating = True
End Sub
This comment was minimized by the moderator on the site
Thanks for sharing
This comment was minimized by the moderator on the site
best graphic design company in india
Designing is a craft of communicating words as articulations. Visuals matter more than words in the advanced field.
The experts in the designing business recommend that illustrations are simpler to recall than words,
and that is the reason Website designing and Graphics play an imperative job.

This comment was minimized by the moderator on the site
Thanks for sharing this useful information.
This comment was minimized by the moderator on the site
This is really insightful article , found it very helpful and informational
This comment was minimized by the moderator on the site
HelloNice post .. Keep sharing.Thank You
This comment was minimized by the moderator on the site
Hello sir,
I love with this post.I really appreciate for this website.Your information is so good and valuable.Lovable idea and concept for sharing this website.
This is an amazing website.This post is nice.
Thanks for sharing
This comment was minimized by the moderator on the site
Hi....Hi, This blog content very technical information, it is on of the best blog i have got. Very interesting and describe in a very easy way.
This comment was minimized by the moderator on the site
Hello,
I am glad to find this useful information Thanks for sharing this amazing article.
There are no comments posted here yet
Load More
Please leave your comments in English
Posting as Guest
×
Rate this post:
0   Characters
Suggested Locations