Re: How do I change the text color on all my slides at one time?



In article <95E50670-00B3-448D-A36E-04EAD9A37688@xxxxxxxxxxxxx>, John Wilson
wrote:
That code looks so useful that Ive made a small change to make it easier to
enter colour values!

Nice touch ... thanks. I've incorporated the change into the one on the FAQ



Sub ChangeFontColor()

Dim R As Integer
Dim G As Integer
Dim B As Integer

R = Val(InputBox("Please input red value"))
G = Val(InputBox("Please input green value"))
B = Val(InputBox("Please input blue value"))

Dim oSld As Slide
Dim oShp As Shape
Dim oShapes As Shapes

For Each oSld In ActivePresentation.Slides
Set oShapes = oSld.Shapes
For Each oShp In oShapes
If oShp.HasTextFrame Then
If oShp.TextFrame.HasText Then
oShp.TextFrame.TextRange.Font.Color.RGB = RGB(R, G, B)
End If
End If
Next oShp
Next oSld
End Sub


-----------------------------------------
Steve Rindsberg, PPT MVP
PPT FAQ: www.pptfaq.com
PPTools: www.pptools.com
================================================


.



Relevant Pages

  • excel to ppt VBA not working
    ... Dim oPPTPres As PowerPoint.Presentation ... Dim oSld As Slide ... Dim oShapes As Shapes ... Dim oShp As Shape ...
    (microsoft.public.excel.misc)
  • Re: Location for backup files?
    ... both here and the FAQ. ... Dim doc1 As Document ... Dim FPath As String ... >> location for the backups to be stored? ...
    (microsoft.public.word.newusers)
  • Re: how to use LinkedFieldID to show linked field ID
    ... Try posting on the developer newsgroup. ... Please see FAQ Item: 24. ... > linked to to create a hammock task. ... > Dim tdep As TaskDependency ...
    (microsoft.public.project)
  • RE: Securing and Splitting Databases
    ... I would strongly encourage you to read the MS Access Security FAQ. ... Dim ws As Workspace ... Dim db As DATABASE ...
    (microsoft.public.access.security)
  • Re: Accessing builtindocumentproperties
    ... Try posting on the developer newsgroup as this one is closing down. ... see FAQ Item: 24. ... Project Newsgroups. ... Dim f As New AddFunction ...
    (microsoft.public.project.vba)