File tree Expand file tree Collapse file tree 2 files changed +7
-4
lines changed Expand file tree Collapse file tree 2 files changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -6,7 +6,10 @@ public class PowerPointApp : HostApplicationBase<Microsoft.Office.Interop.PowerP
6
6
{
7
7
private readonly IVBE _vbe ;
8
8
9
- public PowerPointApp ( IVBE vbe ) : base ( "PowerPoint" ) { }
9
+ public PowerPointApp ( IVBE vbe ) : base ( vbe , "PowerPoint" )
10
+ {
11
+ _vbe = vbe ;
12
+ }
10
13
11
14
public override void Run ( dynamic declaration )
12
15
{
Original file line number Diff line number Diff line change @@ -187,10 +187,10 @@ public IHostApplication HostApplication()
187
187
}
188
188
189
189
var host = Path . GetFileName ( System . Windows . Forms . Application . ExecutablePath ) . ToUpperInvariant ( ) ;
190
- //This needs the VBE as a ctor argument.
191
- if ( host . Equals ( "SLDWORKS.EXE" ) )
190
+ //These need the VBE as a ctor argument.
191
+ if ( host . Equals ( "SLDWORKS.EXE" ) || host . Equals ( "POWERPNT.EXE" ) )
192
192
{
193
- return new SolidWorksApp ( this ) ;
193
+ return ( IHostApplication ) Activator . CreateInstance ( HostAppMap [ host ] , this ) ;
194
194
}
195
195
//The rest don't.
196
196
if ( HostAppMap . ContainsKey ( host ) )
You can’t perform that action at this time.
0 commit comments