Is it possible to open powerpoint from a slideshow macro?

Y

yanwei

Hi

I want to beable to start powerpoint up from a powerpoint slideshow,
ie from a .pps file and open the current file (on display in the
slideshow) in powerpoint, ie where i can edit the file.

Is this possible? if so how?

thanks.
yanwei
 
S

Sonia

Rename the file to give it an extension of .PPT and it will open in edit mode
when you double click it, or open PowerPoint and then go to File > Open. Locate
the file and open it.
--

Sonia Coleman
Microsoft PowerPoint MVP Team
Autorun Software, Templates and Tutorials
http://www.soniacoleman.com
 
Y

yanwei

Hi sonia

Thanks for the reply. Sorry I wasn't very clear with my question
before. What I have at the moment is:

- I have a .pps file open, it's in slideshow mode
- Powerpoint is NOT currently open/running
- The .pps file has a macro

What I want to do is:

1. There is a textbox that will let the user activate the macro by
clicking on it.
2. The macro will change the file.
3. Instead of saving the file, I want to open the modified file using
PowerPoint for editing purposes.

Is this possible?

If not, I am happy to first save the file after modification as a .ppt
file. Can I then open the file using macro for editing in PowerPoint?
Please keep in mind that Powerpoint is not running and I am only
running slideshow (ie. the .pps file).

While I am at it, is there an easier way to get a "Save As" window up
like the ones in MS programs (can look up folders and things, not a
inputbox) without doing my own userform in PowerPoint?

Currently using PowerPoint 2000, MS PowerPoint 9.0 object lib, MS
office 9.0 object lib and ActiveX data object 2.6 lib.

Thanks so much
Yanwei
 
S

Sonia

It sounds like you'll need some VBA, which I don't speak. Others will have to
help you there.

How are you running the slide show if not in PowerPoint?
 
Y

yanwei

Hi Steve

Yes, I have the viewer open NOT PowerPoint. It's just like I have
double clicked on a .pps file on the desktop. I am using VBA(macro). I
want to know if it's possible to use VBA (macro) to open PowerPoint to
edit the current file that is in the viewer.

If it's possible, what do I need to do. I guess this is the most
important part. :)

Yanwei

 
S

Sonia

Steve wasn't kidding. The Viewer does not support macros, VBA, or ActiveX
controls.

yanwei said:
Hi Steve

Yes, I have the viewer open NOT PowerPoint. It's just like I have
double clicked on a .pps file on the desktop. I am using VBA(macro). I
want to know if it's possible to use VBA (macro) to open PowerPoint to
edit the current file that is in the viewer.

If it's possible, what do I need to do. I guess this is the most
important part. :)

Yanwei
 
D

David M. Marcovitz

What Steve and Sonia said and ...

Just because it is a .pps file, doesn't mean it necessarily has to open
in the Viewer. You can adjust your registry to have it open in the
regular PowerPoint (assuming you have regular PowerPoint). From there,
you might be able to run a macro to do what you want, but I'm not sure.
Maybe you can adjust your registry to open a .pps in Edit mode. Then, all
you have to do to return to Edit mode is a link to End Show. These are
just some thoughts, but I don't think any of us are completely clear on
what you want to do.

--David

--
David M. Marcovitz
Director of Graduate Programs in Educational Technology
Loyola College in Maryland
Author of _Powerful PowerPoint for Educators_
http://www.loyola.edu/education/PowerfulPowerPoint/

Steve wasn't kidding. The Viewer does not support macros, VBA, or
ActiveX controls.
 
Y

yanwei

Hi Steve

Sorry that i can't ask the question clear enough. But I managed to get
powerpoint to open. But can't open the file i need.

You said that the viewer does not support VBA, but I still got macro to
work when I am in slideshow mode (and the powerpoint program is not
running). Does that mean that I am not just in the viewer? Basically
just clicking on a .pps file.

I know I can change the registry, but the .pps file will be used on
someone else's computer where I can't and won't be allowed to change
the registry settings. :)

Thanks
Yanwei
 
Y

yanwei

Hi Steve

They will. The main reason I want to open the current modified file in
PowerPoint is so that they can edit the new file.

I am sorry for all this trouble and not asking clear questions as I
don't know how they work. Though I am learning. :) Thanks for your
patience.

Many Thanks
Yanwei
 
Y

yanwei

Hi Steve

This goes back to the problem that PowerPoint does not autorun macros.
To get macros running, either have to have addins (which I can't get
them to do), or run it by going to tools -> macros -> run (which may be
too complicated) and the last option is to have a button like thing to
run the macro in slideshow mode. This is what I am trying to do. When
they double click on the file, slideshow will run, and then click on
the text box to run the macro. After the macro changed the file, open
it in powerpoint to edit the file. This is what I am trying to do.

Does it make sense? Is there an easier way to do it? Am I making
something simple very complicated? ^-^

Thanks
Yanwei
 
Y

yanwei

Hi Steve

Thanks thats what I was thinking of doing if I couldn't get my open it
directly.

Thanks again.Do I need to start a new posting about text overflow? I
want to keep the text, and if there is more text than the box can hold,
can I keep the text but only show the part that can be appear within
the boundaries of the textbox?

Many thanks again.
Yanwei
 
Y

yanwei

Hi Steve

Since I saved that file, is it possible to get rid of it after I opened
it? Here is my code:

ActivePresentation.SaveAs "~tmp", ppSaveAsPresentation
With PowerPoint.Presentations.Open("~tmp.ppt", msoFalse, msoTrue,
msoFalse)
.Application.Visible = msoTrue
.Saved = msoFalse
End With
PowerPoint.Presentations(1).Close

I have set it up so the user will get a SaveAs window when ever they
want to save, so they can't save to the file that I created.

The macro will only be active if the orignal (Presentations(1)) is
still open. The new file "~tmp.ppt" will have the macro, but it will
not run until activeated. So is it possible to delete the "~tmp.ppt"
file that I created, before the presentations(1) is closed? I tried
the following:

FileSystem.Kill ActivePresentation.Path & "~tmp.ppt"

but as expected, I was not allowed to do it, got error of permission
denied.

My assumption/guess is I can't do it, but I am trying my luck. If it is
not possible to do it before it's closed, is there a way to get ride of
it at all (err. i don't mean by the user. :) )?


Thanks
Yanwei
 
Y

yanwei

Hi Steve

Please ignored that last question. I found out that the macro does not
end at the point when I close the presentation. So I was able to delete
the file after I close the presentation. I am now very very happy. :)

Thanks for your help.
Yanwei
 
Y

yanwei

Hi Steve:

Thanks for the suggestion, it will come in very handy in the future. :)
Can you arrange to have your customer sent on a four or five year vacation
to Antarctica instead? ;-)

Truth to be told I don't mind a holiday in Antarctica myself, but it's
very expensive. So if the opportunity does come up, I would have taken
it before handing it to someone else. ^-^ Though, may be not four or
five years. ;)

Have Fun!
Yanwei
 
Top