Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@KaitoHH
Last active July 5, 2017 08:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save KaitoHH/34840c30fe1b17752068366f5c9a237e to your computer and use it in GitHub Desktop.
Save KaitoHH/34840c30fe1b17752068366f5c9a237e to your computer and use it in GitHub Desktop.
change into rainbow color for every single characters (tested on Microsoft Word 2016)
Sub color()
Application.ScreenUpdating = False
Dim i As Long
Dim color
'rainbow color
color = Array(8388736, 255, 33023, 65535, 65280, 16776960, 16711680)
With ActiveDocument
For i = 1 To .Characters.Count
.Characters(i).Font.color = color(i Mod 7)
Next
End With
Application.ScreenUpdating = True
End Sub
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment