打开视图→模板,删去ppt底色。回到普通视图模式,打开工具→宏→宏,在宏名处随便写几个字母,点击创建。将自动生成语句全部删除,替换成如下程序,保存后关闭。再打开打开工具→宏→宏,宏名处为Recolor,点击运行后保存。(若未出现运行选项,打开工具→宏→安全性,设置为中,重新打开文件)再次打印预览时可见公式。'VBAcannotpassShapeintoafunction,soglobalvarisusedPublicshAsShape'ThemacrotoexcuteSubReColor()DimsldAsSlideForEachsldInActivePresentation.SlidesForEachshInsld.ShapesCallReColorSHNextNextEndSubSubReColorSH()DimipAsInteger'pointtothetopoftheistackDimspAsInteger'pointtothetopoftheshapestackDimistk()AsInteger'theistack,usingdynamicarrayDimsstk()AsShape'theShapestack,usingdynamicarrayDimssizeAsInteger'thesizeofbothstacksssize=10ReDimistk(ssize)ReDimsstk(ssize)ip=0sp=0DimiAsIntegerL2:Ifsh.Type=msoGroupTheni=1L1:'pushS(sh)sp=sp+1IfspssizeThenssize=ssize+1ReDimPreserveistk(ssize)ReDimPreservesstk(ssize)EndIfSetsstk(sp)=sh'----------'pushI(i)ip=ip+1istk(ip)=i'----------Setsh=sh.GroupItems(i)GoToL2L3:'popI(i)i=istk(ip)ip=ip-1'----------'popS(sh)Setsh=sstk(sp)sp=sp-1'----------Ifish.GroupItems.CountTheni=i+1GoToL1EndIfElseIfsh.Type=msoEmbeddedOLEObjectThenIfLeft(sh.OLEFormat.ProgID,8)=EquationThensh.BlackWhiteMode=msoBlackWhiteBlackEndIfEndIfIfip0ThenGoToL3EndSub