View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Tim Williams[_2_] Tim Williams[_2_] is offline
external usenet poster
 
Posts: 298
Default Programatically Export Excel Chart to Graphic in SharePoint

Have you tried replacing the %20 with a space ?

Tim

"Travis" wrote in message
...
I have been using the following VBA command to export Excel charts to
graphics. This works perfectly for local or network storage.

Worksheets(1).ChartObjects(1).Chart.Export
Filename:="Filepath\Filename.gif", filtername:="GIF"

When I modify to save to SharePoint site as follows it returns Error
-2146697210 (800c0006).

Worksheets(1).ChartObjects(1).Chart.Export
Filename:="http://ms-proto/TeamFolder/Shared%20Documents/Filename.gif",
filtername:="GIF"

I have tried the application.workbooks.saveas command to save the
workbook,
and that does work to save into sharepoint. Any suggestions?