I'm trying to use MS Project 2013 to open a filechooser box, select a .pptx file, and open it.
If I write down the filepath inside VBA, my code opens the pptx without any problem and do what it has to do.
My problem is that somehow I can't use the msoFileDialogFilePicker object. I've set my references to use MS Word Object Library, Visual basic for Applicaitons, and even Excel Object, but the Application object doesnt recognize it no matter what reference I choose.
I've also tried getOpenFilename method, but the application doesnt recognize it either.
Heres my code so far:
Dim strTemplatePPT As String
strTemplatePPT = Application.GetOpenFilename("Modelos de PowerPoint,*.pptx*", 1, "Abrir Arquivo", , False)
Set ppAppl = CreateObject("PowerPoint.Application")
ppAppl.Visible = True
Set ppPres = ppAppl.Presentations.Open(strTemplatePPT, msoFalse)
Have anyone had this problem?
Thanks.