By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
434,696 Members | 1,424 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 434,696 IT Pros & Developers. It's quick & easy.

Need help with PowerPoint

P: 12
Hi there,

I hope you can help me. I did download some code, from the Microsoft knolidgebase(MSDN), and it's great. I just don't know how to change the code so that it uses a template, thats on my computer, instate of a blank page.
Also i want to controle the presentation with a mouse click(or both). Now it's changing a slide after 5 sec. if i press the mouse button nothing hapens.

thank you for helping me.... :)

here is the code:

' Start PowerPoint.
Dim ppApp As PowerPoint.Application
Set ppApp = CreateObject("Powerpoint.Application")

' Maak de toepassing zichtbaar.
ppApp.Visible = True

' Voeg een nieuwe presentatie toe.
Dim ppPres As PowerPoint.Presentation
Set ppPres = ppApp.Presentations.Add(msoTrue)

' Voeg een nieuwe dia toe.
Dim ppSlide1 As PowerPoint.Slide
Set ppSlide1 = ppPres.Slides.Add(1, ppLayoutText)

' Voeg wat tekst toe.
ppSlide1.Shapes(1).TextFrame.TextRange.Text = txtTekst1.Text '"Mijn eerste dia"
ppSlide1.Shapes(2).TextFrame.TextRange.Text = txtTekst2.Text '"PowerPoint automatiseren is een makkie" & vbCr & "Werken met Visual Basic is cool!"

' Stel eigenschappen van de diavoorstelling in.
With ppPres.Slides.Range.SlideShowTransition
.EntryEffect = ppEffectRandom
.AdvanceOnTime = msoTrue
.AdvanceTime = 5 ' 5 seconds per slide
End With

' Bereid de diavoorstelling voor en voer deze uit.
With ppPres.SlideShowSettings
.ShowType = ppShowTypeKiosk
.LoopUntilStopped = msoTrue

.RangeType = ppShowAll
.AdvanceMode = ppSlideShowUseSlideTimings
End With

' Slaapstand inschakelen, zodat gebruiker diavoorstelling kan bekijken.
Sleep (15000)

' Opschonen.
Aug 30 '06 #1
Share this question for a faster answer!
Share on Google+

Post your reply

Sign in to post your reply or Sign up for a free account.