VBA - Publishing html reports on Sharepoint (check in / check out)

seeyah

New Member
Joined
May 2, 2014
Messages
1
Hello,

I have been struggling for the past two days on the following problem :
I would like to publish a series of reports as .html files (web pages) on a sharepoint site with VBA, without having to worry whether I have to check in or check out the uploaded files.

Result :
The html publication is working fine, the problem is that the following code let the published files checked out on sharepoint, hence If i don't manually check in all the files (even the different graphs in the relevant folder), other users cannot see the different reports.

Code:
With ActiveWorkbook.PublishObjects.Add(xlSourceSheet, _        "https://...../report.htm" _
        , "Reporting", "", xlHtmlStatic, _
        "HP QC", "Reporting")
        .Publish (True)
        .AutoRepublish = False
    End With

I know how to check in / check out a workbook, however the checkin method doesn't seem to work with html reports. My questions :
- Is there a solution to check in / check out html files (and generated misc files) with VBA ?
- Alternatively, if the check in / check out mechanism cannot be implemented, would it be at least possible from excel to publish and check in these html reports, but whenever I have to update them I juste delete with VBA the different files and upload them again ?

Finally there are two requirements, these reports have to be in .html (Web Page) as they are then used by another application hence I cannot use the Single File Web Page for exemple, also they should always have the same name.

Any solution would be more than welcome

Many thanks
 

Excel Facts

How to show all formulas in Excel?
Press Ctrl+` to show all formulas. Press it again to toggle back to numbers. The grave accent is often under the tilde on US keyboards.

Forum statistics

Threads
1,216,750
Messages
6,132,499
Members
449,730
Latest member
SeanHT

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top