I have been trying for a few days to open a .pps file (power point slide show) from within my program, I have tried the following.

ShellExecute(NULL, "open", "\\Test.ppt", NULL, "C:\\Program Files\\Pyrosoft\\Utilities", SW_MAXIMIZE);

system("start C:\\Program Files\\Pyrosoft\\Utilities\\Test.ppt");

Both methods can open .txt files, in the same folder, but not .ppt
I have also tried with 2 different programs to converty the .ppt to an avi video and run it that way, which, didn't work either.

Does anyone know either why it wont open it, or another way to go about it?

Thanks,
Matt

When you double click the *.pps file does it then open?

If it does try checking what app is used to open *.pps files.

Yes it opens when I run it by itself.

Matt

How about using powerpoint to open the file?
Or would that be too obvious? :)

Well, the goal is to open it with code, I am aware I can just go and click the file.

It would be much more professional looking if the program has a button to do this rather then making the user navigate to the ppt and run it that way.

Matt

What he meant(i think) is that you could do this. ShellExecute(0, 0, "<program to open program with>", "<file to open>", 0, SW_MAXIMIZE); This is ofcourse not optimal but it can be used as an emergency solution.