Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11
Default Question on using Form's Button in Excel

I use a button in Excel to call a file into Excel. Can I
use a button in excel to open up another Office
application such as Powerpoint?
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 44
Default Question on using Form's Button in Excel

Hi,
Yes, one way:

Private Sub CommandButton1_Click()
callppt
End Sub

Sub callppt()
x = Shell("C:\Program Files\Microsoft Office\Office10
\POWERPNT.EXE")
End Sub

jeff
-----Original Message-----
I use a button in Excel to call a file into Excel. Can I
use a button in excel to open up another Office
application such as Powerpoint?
.

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11
Default Question on using Form's Button in Excel

Jeff,

Thanks so much, it worked. I have another question. Can a
powerpoint file be opened up thru this CommandButton in
excel (First open up powerpoint then open up the file I
need).

Thanks,

Bert

-----Original Message-----
Hi,
Yes, one way:

Private Sub CommandButton1_Click()
callppt
End Sub

Sub callppt()
x = Shell("C:\Program Files\Microsoft Office\Office10
\POWERPNT.EXE")
End Sub

jeff
-----Original Message-----
I use a button in Excel to call a file into Excel. Can I
use a button in excel to open up another Office
application such as Powerpoint?
.

.

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,120
Default Question on using Form's Button in Excel

Sure it can

Set pptApp = CreateObject(,"Powerpoint.Application")
pptApp.V isible = True
pptApp.Presentations.Open FileName:="c:\My Documents\pres1.ppt"

--
HTH

-------

Bob Phillips
"Bert" wrote in message
...
Jeff,

Thanks so much, it worked. I have another question. Can a
powerpoint file be opened up thru this CommandButton in
excel (First open up powerpoint then open up the file I
need).

Thanks,

Bert

-----Original Message-----
Hi,
Yes, one way:

Private Sub CommandButton1_Click()
callppt
End Sub

Sub callppt()
x = Shell("C:\Program Files\Microsoft Office\Office10
\POWERPNT.EXE")
End Sub

jeff
-----Original Message-----
I use a button in Excel to call a file into Excel. Can I
use a button in excel to open up another Office
application such as Powerpoint?
.

.



  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 107
Default Question on using Form's Button in Excel

I think a stray comma and a stray space crept in there.

Dim pptApp As Object
Set pptApp = CreateObject("Powerpoint.Application")
pptApp.Visible = True
pptApp.Presentations.Open filename:="c:\My Documents\pres1.ppt"



Bob Phillips wrote:

Sure it can

Set pptApp = CreateObject(,"Powerpoint.Application")
pptApp.V isible = True
pptApp.Presentations.Open FileName:="c:\My Documents\pres1.ppt"




  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11
Default Question on using Form's Button in Excel

When I try to run this I get a "Run-Time Error". Here's
the Code. Can you help me with this, Thanks:


Private Sub CommandButton1_Click()
callppt

End Sub

Sub callppt()
x = Shell("C:\Program Files\Microsoft
Office\Office\POWERPNT.EXE")

Dim pptApp As Object
Set pptApp = CreateObject("Powerpoint.Application")
pptApp.Visible = True
pptApp.Presentations.Open
Filename:="U\DATA\POWER\Learning.ppt"







-----Original Message-----
I think a stray comma and a stray space crept in there.

Dim pptApp As Object
Set pptApp = CreateObject("Powerpoint.Application")
pptApp.Visible = True
pptApp.Presentations.Open filename:="c:\My

Documents\pres1.ppt"



Bob Phillips wrote:

Sure it can

Set pptApp = CreateObject(,"Powerpoint.Application")
pptApp.V isible = True
pptApp.Presentations.Open FileName:="c:\My

Documents\pres1.ppt"


.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Having one form show another form's input? Lucosa New Users to Excel 3 June 13th 06 04:16 PM
X button question Greg B Excel Discussion (Misc queries) 2 September 19th 05 12:47 AM
Problems with a Form's behaviour Stuart[_5_] Excel Programming 0 December 22nd 03 06:43 PM
A Form's Rowsourse Format John T Ingato Excel Programming 2 October 15th 03 06:42 PM
Pass Variables into Form's code Stuart[_5_] Excel Programming 3 August 23rd 03 04:55 AM


All times are GMT +1. The time now is 07:28 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"