Creating a macro in Word (Office 365) to automate insertion of text


  1. Posts : 54
    Windows 10 Home
       #1

    Creating a macro in Word (Office 365) to automate insertion of text


    Hello all,

    i receive a document that is always in the same format. I have to manually change the layout of the document, including adding Headers & Footers, text and horizontal lines.
    i tried to create a macro to run but it didn't work.
    Any ideas to automate this formatting?
    Thanks

    Creating a macro in Word (Office 365) to automate insertion of text-image.png
      My Computer


  2. Posts : 18,044
    Win 10 Pro 64-bit v1909 - Build 18363 Custom ISO Install
       #2

    Hello @Funjunkie6,

    Funjunkie6 said:
    i receive a document that is always in the same format. I have to manually change the layout of the document, including adding Headers & Footers, text and horizontal lines.
    i tried to create a macro to run but it didn't work.
    Any ideas to automate this formatting?

    It has been MANY years since I created and used a Macro [ VBA ]. I did investigate this to try and get you started and came across these . . .

    > Create or Run a Macro
    > Word: Macro to Convert from One Style to Another
    > Templates and Page Setup

    If you are familiar with using Macros, you could record one and then edit out all the extra code that gets created that is superfluous.

    I hope this at least helps in some way!
      My Computer


  3. Posts : 54
    Windows 10 Home
    Thread Starter
       #3

    Thanks Paul.
    i’ll give it a go!
    appreciate your help ��
      My Computer


  4. Posts : 18,044
    Win 10 Pro 64-bit v1909 - Build 18363 Custom ISO Install
       #4

    Hello @Funjunkie6,

    Funjunkie6 said:
    Thanks Paul.
    I’ll give it a go!
    Appreciate your help.
    You are VERY welcome. I hope it helps in some way.
      My Computer


  5. Posts : 16,950
    Windows 10 Home x64 Version 22H2 Build 19045.4170
       #5

    Funjunkie6 said:
    i tried to create a macro to run but it didn't work.
    1 What did and did not happen when you tried it?

    Funjunkie6 said:
    Any ideas to automate this formatting?
    Funjunkie6 said:
    i receive a document that is always in the same format. I have to manually change the layout of the document, including adding Headers & Footers, text and horizontal lines.
    2 Please post your code and make sure you include explanations of what you are trying to do at each stage [i.e. write out your list of instructions for each stage as though you were telling somebody to do the job for you manually].
    3 Are you used to working with macros? Macro recordings or writing VBA code?

    4 Why don't you tell the document's author to use the layout you want before sending it to you?

    All the best,
    Denis
    Last edited by Try3; 20 May 2021 at 08:41.
      My Computer


 

  Related Discussions
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 22:30.
Find Us




Windows 10 Forums