Colorize smartart Graphics with VBA in PowerPoint

I

ingrid makkinje

Since I could not find a section for PowerPoint and VBA I drop my question
here.
I would like to change to fill color of one of the elements of a smartart
graphics,
Below listed is the code that I normally used for changing Autoshapes, but
this does not work anymore. I hope someone can help me with this.


Public Sub FillColor1()
'On Error GoTo Errorhandler

With ActiveWindow.Selection.ShapeRange
..Fill.Visible = msoTrue
..Fill.Solid
..Fill.ForeColor.RGB = RGB(143, 199, 255)
End With
ActiveWindow.BlackAndWhite = msoTrue
ActiveWindow.Selection.ShapeRange.BlackWhiteMode = msoBlackWhiteAutomatic
ActiveWindow.BlackAndWhite = msoFalse
Exit Sub
Errorhandler:
MsgBox "Nothing appropriate is currently selected", vbOKOnly, "User
Error"
End Sub
 
J

Jean-Guy Marcil

ingrid makkinje was telling us:
ingrid makkinje nous racontait que :
Since I could not find a section for PowerPoint and VBA I drop my
question here.
I would like to change to fill color of one of the elements of a
smartart graphics,
Below listed is the code that I normally used for changing
Autoshapes, but this does not work anymore. I hope someone can help
me with this.


Public Sub FillColor1()
'On Error GoTo Errorhandler

With ActiveWindow.Selection.ShapeRange
.Fill.Visible = msoTrue
.Fill.Solid
.Fill.ForeColor.RGB = RGB(143, 199, 255)
End With
ActiveWindow.BlackAndWhite = msoTrue
ActiveWindow.Selection.ShapeRange.BlackWhiteMode =
msoBlackWhiteAutomatic ActiveWindow.BlackAndWhite = msoFalse
Exit Sub
Errorhandler:
MsgBox "Nothing appropriate is currently selected", vbOKOnly, "User
Error"
End Sub

What is a "smartart graphic"?
 
M

makkinje.ingrid

ingrid makkinje was telling us:
ingrid makkinje nous racontait que :








What is a "smartart graphic"?

--
______________________________
Jean-Guy Marcil
Montreal, Canada- Hide quoted text -

- Show quoted text -

Thank you Jean-Guy for your reply. Smart Art is a new tool in office
2007. You can create Lists, Process Arrows, Matrices, etc. It looks
like the old Diagram tool (Insert menu in PowerPoint 2003).
Ingrid
 
C

Cindy M.

Hi Ingrid,
Since I could not find a section for PowerPoint and VBA I drop my question
here.

Just ask your question in the one-and-only PowerPoint newsgroup. They handle
both end-user and developer-level questions in the same group :)

It will probably help them if you can be more specific about what type of
"Shape" (SmartArt?) you're trying to affect with this code.

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 17 2005)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow question or
reply in the newsgroup and not by e-mail :)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top