|
|
|
date: Tue, 9 Sep 2008 05:05:42 -0700 (PDT),
group: microsoft.public.office.developer.automation
back
Re: How to open Password Protected PPT File
In article ,
Miztaken wrote:
> Hi there,
> I dont know if this the right forum to ask this question or not? If
> not, please guide me through.
> If yes,
> I need to supply password to PPT file progrmatically.
> I am using Office Interop and .NET 2.0 (C#)
> I am coding like this:
> ApplicationClass appPowerPoint = new ApplicationClass();
> Presentation presentation =
> appPowerPoint.Presentations.Open(FileName,
> Microsoft.Office.Core.MsoTriState.msoCTrue,
> Microsoft.Office.Core.MsoTriState.msoCTrue,
> Microsoft.Office.Core.MsoTriState.msoCTrue);
> As you can see Presentations.Open dont have any argument where i can
> input password.
> For word and excel password input argument is available but i cant
> find that for PPT.
> I do know there is presentation.Password variable, but we can use
> this
> only after PPT is opened?
> So can anybody help me figure out what am i missing?
Nothing. MS hasn't exposed any methods for opening password protected files in
PPT. As a hack/workaround, you could work out the name of the dialog box that
appears when you open a protected file, then send keystrokes to it to feed it
the password.
--
Steve Rindsberg, PPT MVP
PPT FAQ: www.pptfaq.com
PPTools: www.pptools.com
================================================
date: Fri, 12 Sep 2008 00:27:29 EDT
author: Steve Rindsberg
Re: How to open Password Protected PPT File
I have the same problem.....
Even with the workaround the problem remains because in that moment I
don't have the control of the application, but PP has....
So my code won't be executed until the operator will press the "OK" or the
"Cancel"
button, only in that moment I get again the control of the application and I
can
use the sendkey function......
The only way I see is to create another program that waits for the PP
messagebox
the be shown and then work on it, but it's terribly ugly ........
cheers
__Danilo
"Steve Rindsberg" wrote:
> In article ,
> Miztaken wrote:
> > Hi there,
> > I dont know if this the right forum to ask this question or not? If
> > not, please guide me through.
> > If yes,
> > I need to supply password to PPT file progrmatically.
> > I am using Office Interop and .NET 2.0 (C#)
> > I am coding like this:
> > ApplicationClass appPowerPoint = new ApplicationClass();
> > Presentation presentation =
> > appPowerPoint.Presentations.Open(FileName,
> > Microsoft.Office.Core.MsoTriState.msoCTrue,
> > Microsoft.Office.Core.MsoTriState.msoCTrue,
> > Microsoft.Office.Core.MsoTriState.msoCTrue);
> > As you can see Presentations.Open dont have any argument where i can
> > input password.
> > For word and excel password input argument is available but i cant
> > find that for PPT.
> > I do know there is presentation.Password variable, but we can use
> > this
> > only after PPT is opened?
> > So can anybody help me figure out what am i missing?
>
> Nothing. MS hasn't exposed any methods for opening password protected files in
> PPT. As a hack/workaround, you could work out the name of the dialog box that
> appears when you open a protected file, then send keystrokes to it to feed it
> the password.
>
> --
> Steve Rindsberg, PPT MVP
> PPT FAQ: www.pptfaq.com
> PPTools: www.pptools.com
> ================================================
>
>
date: Thu, 16 Oct 2008 09:40:01 -0700
author: Danilo
Re: How to open Password Protected PPT File
In article , Danilo wrote:
> I have the same problem.....
> Even with the workaround the problem remains because in that moment I
> don't have the control of the application, but PP has....
> So my code won't be executed until the operator will press the "OK" or the
> "Cancel"
> button, only in that moment I get again the control of the application and I
> can
> use the sendkey function......
>
> The only way I see is to create another program that waits for the PP
> messagebox
> the be shown and then work on it, but it's terribly ugly ........
Sometimes ugly is the only way to triumph over ugly, I guess. <g>
>
> cheers
> __Danilo
>
> "Steve Rindsberg" wrote:
>
> > In article ,
> > Miztaken wrote:
> > > Hi there,
> > > I dont know if this the right forum to ask this question or not? If
> > > not, please guide me through.
> > > If yes,
> > > I need to supply password to PPT file progrmatically.
> > > I am using Office Interop and .NET 2.0 (C#)
> > > I am coding like this:
> > > ApplicationClass appPowerPoint = new ApplicationClass();
> > > Presentation presentation =
> > > appPowerPoint.Presentations.Open(FileName,
> > > Microsoft.Office.Core.MsoTriState.msoCTrue,
> > > Microsoft.Office.Core.MsoTriState.msoCTrue,
> > > Microsoft.Office.Core.MsoTriState.msoCTrue);
> > > As you can see Presentations.Open dont have any argument where i can
> > > input password.
> > > For word and excel password input argument is available but i cant
> > > find that for PPT.
> > > I do know there is presentation.Password variable, but we can use
> > > this
> > > only after PPT is opened?
> > > So can anybody help me figure out what am i missing?
> >
> > Nothing. MS hasn't exposed any methods for opening password protected files in
> > PPT. As a hack/workaround, you could work out the name of the dialog box that
> > appears when you open a protected file, then send keystrokes to it to feed it
> > the password.
> >
> > --
> > Steve Rindsberg, PPT MVP
> > PPT FAQ: www.pptfaq.com
> > PPTools: www.pptools.com
> > ================================================
> >
> >
>
--
Steve Rindsberg, PPT MVP
PPT FAQ: www.pptfaq.com
PPTools: www.pptools.com
================================================
date: Thu, 16 Oct 2008 22:30:44 EDT
author: Steve Rindsberg
|
|