Guest User

Untitled

a guest
Dec 19th, 2018
66
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.17 KB | None | 0 0
  1. 'Example of how I access the native table in PowerPoint
  2. Set oPPTShape = oPPTFile.Slides(SlideNum).Shapes("Table1")
  3.  
  4. 'I can get data from a cell by using, for example:
  5. oPPTShape.Table.Cell(2, 1).Shape.TextFrame.TextRange.Text
  6. 'But I cannot select a range from this PowerPoint table
  7.  
  8. With OutMail
  9.  
  10. .To = name_email
  11. 'Add file
  12. .Attachments.Add ("C:... .pptx")
  13. .Subject = "Data"
  14. .Body = StrBody
  15. .HTMLBody = StrBody & RangetoHTML(rng)
  16. .SaveAs "C:... .msg", 5
  17. .Display 'Or use .Send
  18.  
  19. End With
  20.  
  21. Dim strNewPresPath As String
  22. strNewPresPath = "C:... .pptx"
  23.  
  24. Set oPPTApp = CreateObject("PowerPoint.Application")
  25. oPPTApp.Visible = msoTrue
  26.  
  27. Set oPPTFile = oPPTApp.Presentations.Open(strNewPresPath)
  28. SlideNum = 1
  29.  
  30. Sheets("Open Tasks").Activate
  31.  
  32. Dim myStr As String
  33. myStr = "Open"
  34.  
  35. Do
  36. oPPTFile.Slides(SlideNum).Select
  37. 'Select PowerPoint shape with the name Table1
  38. Set oPPTShape = oPPTFile.Slides(SlideNum).Shapes("Table1")
  39. .
  40. .
  41. .
Add Comment
Please, Sign In to add comment