Ignore hidden slides when printing a table of contents in VBA - Powerpoint -
i trying write table of contents @ begining of powerpoint presentation.
the code have fetches slide have title, , print them along index.
i know can find command determine wether or not slide hidden. have searched msdn vba powerpoint section, came empty.
for example, current project :
for y = 3 activepresentation.slides.count set diapo = activepresentation.slides(y) 'si la diapo un titre if diapo.shapes.hastitle set titre = diapo.shapes.title texte_ajout = texte_ajout & format(y, "0 - ") & titre.textframe. _ textrange.text & chr(13) & vbcrlf end if next y
it counts of slides, including might hidden.
i (if possible) write before first if , after set diapo
if diapo.slideshowtransition.hidden = msotrue set counthidden = counthidden + 1
...
texte_ajout = texte_ajout & format(y-counthidden, "0 - ") & titre.textframe. _ textrange.text & chr(13) & vbcrlf end if
(i defined counthidden byte first, long, it's not working) possible?
here go ;)
for y = 3 activepresentation.slides.count set diapo = activepresentation.slides(y) if diapo.slideshowtransition.hidden = msotrue 'other value : msofalse counthidden = counthidden + 1 else 'the slide not hidden if diapo.shapes.hastitle 'si la diapo un titre set titre = diapo.shapes.title texte_ajout = texte_ajout & format(y - counthidden, "0 - ") & titre.textframe. _ textrange.text & chr(13) & vbcrlf end if end if next y
Comments
Post a Comment