View Single Post
 
Old 01-09-2015, 05:46 AM
gerris gerris is offline Windows 7 64bit Office 2010 64bit
Novice
 
Join Date: Dec 2014
Posts: 5
gerris is on a distinguished road
Default PP Command Button wont run on another PC

Does anybody know why a PP Presentation with Counter Button will run on my PC but when I email it to somebody else - it wont run on theirs and they do have the same version of PP.

I tried the VB code as suggested in this forum

Dim Offset As Single
Dim CountNo As Long
Dim x As Single

Private Sub CommandButton1_Click()
Offset = ActivePresentation.PageSetup.SlideHeight + 10
CountNo = 0
' ADJUST THIS waitTime NUMBER WITH SECONDS DELAY BETWEEN COUNTER INCREMENTS
waitTime = 0.5
' ADJUST THIS maxCount NUMBER WITH MAXIMUM NUMBER COUNTER SHOULD REACH
maxCount = 5000
Do Until CountNo = maxCount + 1
ActivePresentation.SlideMaster.Shapes("Counter").T extFrame.TextRange.Text = CountNo
ActivePresentation.SlideMaster.Shapes("Counter").T op = ActivePresentation.SlideMaster.Shapes("Counter").T op + Offset
DoEvents
ActivePresentation.SlideMaster.Shapes("Counter").T op = ActivePresentation.SlideMaster.Shapes("Counter").T op - Offset
x = Timer
While Timer - x < waitTime
DoEvents
Wend
CountNo = CountNo + 92

If SlideShowWindows.Count = 0 Then
ActivePresentation.SlideMaster.Shapes("Counter").T extFrame.TextRange.Text = 1
ActivePresentation.SlideMaster.Shapes("Counter").T op = ActivePresentation.SlideMaster.Shapes("Counter").T op + Offset
DoEvents
ActivePresentation.SlideMaster.Shapes("Counter").T op = ActivePresentation.SlideMaster.Shapes("Counter").T op - Offset
Exit Do
End If

Loop
End Sub


It works perfectly on my PC. Any ideas ? Thanks
Reply With Quote