Guest User

Untitled

a guest
Jan 23rd, 2019
210
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.19 KB | None | 0 0
  1. Public Sub PopUpBattleTimes3()
  2. BattleCounter = 0
  3. SlideShowWindows(1).View.GotoSlide (7)
  4.  
  5. Dim oShp1 As Shape
  6. Dim oShp2 As Shape
  7. Dim oShp3 As Shape
  8.  
  9.  
  10. Dim valuex As Integer
  11. Dim valuey As Integer
  12.  
  13. valuex = CInt(Int((800 * rnd()) + 10))
  14. valuey = CInt(Int((500 * rnd()) + 10))
  15. Set oShp1 = ActivePresentation.Slides(7).Shapes.AddShape(msoShapeActionButtonCustom, valuex, valuey, 80, 50)
  16. oShp1.TextFrame.TextRange.Text = "Object 1"
  17. With oShp1.ActionSettings(ppMouseClick)
  18. .Action = ppActionRunMacro
  19. .Run = "AddToCounter"
  20. End With
  21.  
  22.  
  23. valuex = CInt(Int((800 * rnd()) + 10))
  24. valuey = CInt(Int((500 * rnd()) + 10))
  25. Set oShp2 = ActivePresentation.Slides(7).Shapes.AddShape(msoShapeActionButtonCustom, valuex, valuey, 80, 50)
  26. oShp2.TextFrame.TextRange.Text = "Object2"
  27. With oShp2.ActionSettings(ppMouseClick)
  28. .Action = ppActionRunMacro
  29. .Run = "AddToCounter"
  30. End With
  31.  
  32. valuex = CInt(Int((800 * rnd()) + 10))
  33. valuey = CInt(Int((500 * rnd()) + 10))
  34. Set oShp3 = ActivePresentation.Slides(7).Shapes.AddShape(msoShapeActionButtonCustom, valuex, valuey, 80, 50)
  35. oShp3.TextFrame.TextRange.Text = "Object3"
  36. With oShp1.ActionSettings(ppMouseClick)
  37. .Action = ppActionRunMacro
  38. .Run = "AddToCounter"
  39. End With
  40. End Sub
Add Comment
Please, Sign In to add comment