Okay that became part of my solution... since my goal is simply to 'skip' password protected files I was able to attempt to open them with a dummy password and catch the exception and simply report that back to the user.
On the other hand, some of these files are read-only capable and require a password for 'modifications'. When you open these files by hand you get the dialog that let's you click 'open as read-only' and continue to open and export the document by hand...
I can't figure a way to handle this situation via the interop either... I've tried opening with ReadOnly (goes for office/excel documents too) but it still pops up the dialog, so I have to spawn the process in a Thread and give it a timeout, assuming if it
doesn't open then it's probably asking for a password. I'm ok with this, but wouldn't mind a more robust solution.
Guess we're stuck without a smooth interop into office, we'll have to live with the one we got for now!
long story short here's the rough outline of my solution:
Application powerPoint = new PowerPoint.Application();
throw new Exception("Can't open, took too long, probably requires password...etc...etc.");
else
// processfile....
try/catch around the open to catch the 'invalid password' issue if you want... use powerPoint.ProtectedViewWindows.Open with a fake password and it will throw it there...