ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Linking powerpoint to Excel (https://www.excelbanter.com/excel-programming/285141-linking-powerpoint-excel.html)

j[_3_]

Linking powerpoint to Excel
 
Hi,

I am trying to change the link in a powerpoint object
to a excel file through VBA. The excel file is just
created and not saved. The code follows:

For Each s1 In ppobj.ActivePresentation.Slides
For Each s In s1.Shapes
If s.Type = msoLinkedOLEObject Then
With s.LinkFormat
.SourceFullName = lspresdef & ".xls"
.Update
End With
End If
Next
Next

This gives an error in sourcefullname. If i give a saved
filename with full path it works fine. Can someone help me
in changing the link to an unsaved excel file??


Kurt[_5_]

Linking powerpoint to Excel
 
I think the problem is due to your unsaved excel file. When you link to a
file, the file should exist.
Maybe have a look at www.take-off.as/datapoint
There you'll find a powerpoint addon that links powerpoint dynamically to
text files, databases and excel files.
Kurt.

"j" wrote in message
...
Hi,

I am trying to change the link in a powerpoint object
to a excel file through VBA. The excel file is just
created and not saved. The code follows:

For Each s1 In ppobj.ActivePresentation.Slides
For Each s In s1.Shapes
If s.Type = msoLinkedOLEObject Then
With s.LinkFormat
.SourceFullName = lspresdef & ".xls"
.Update
End With
End If
Next
Next

This gives an error in sourcefullname. If i give a saved
filename with full path it works fine. Can someone help me
in changing the link to an unsaved excel file??





All times are GMT +1. The time now is 05:16 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com