How to Auto Replace in Google Docs With Capitalization & Formatting

Suppose you want to replace

YouTube as YouTube
Google Drive as Google Drive
Google docs  inbuilt with auto replacing tool, but it Cannot   capitalize for format your text .There are many addons that is   promising to do this but they are not capable of doing this .If you want to replace and format your text that means replace your text with formatted text then in this should go to manually find this and then replace so this is something lengthy process and it takes. time this task can be simplified by using Google script. but again this is limited to some word that you have put into your script so whenever you want to replace something by some new text formatted you have to put this into a script editor and then this task will be completed accordingly. now to simplify this task I have created a  Google sheet .


  • in this sheet you have to enter the word that is to be replaced  and the replace word.
Coming to the point link of the sheet  is here.

You must sort  column D according to length of the character, to do this you can simply sort column app Z to A.
this will give you best result on replace in   replaced word. you can also automatic this sorting buy a macro  or script.
In   column D enter word ;
In column E Enter Replace  word;
Go to sheet2 copy  script.
Go to script editor from tools menu.

paste the copied code Into a script editor.
Click on edit menu select  current project Trigger.
set a trigger to run this script every minute.

now your word will be replaced in maximum of 1 minute as you have set to be.

No comments:

Post a Comment