Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/vba/14.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Vba 使用OutputTo保存到SharePoint 2010文档库时使用RTE 2501,但保存到本地HDD时效果良好_Vba_Sharepoint 2010_Runtime Error_Ms Access 2010 - Fatal编程技术网

Vba 使用OutputTo保存到SharePoint 2010文档库时使用RTE 2501,但保存到本地HDD时效果良好

Vba 使用OutputTo保存到SharePoint 2010文档库时使用RTE 2501,但保存到本地HDD时效果良好,vba,sharepoint-2010,runtime-error,ms-access-2010,Vba,Sharepoint 2010,Runtime Error,Ms Access 2010,我有一个MS Access 2010数据库,可以创建PDF,然后将文件保存到SharePoint 2010文档库。这已经运行了好几年了,但是现在我得到了一个2501运行时错误“输出操作被取消” 我可以将保存路径更改为本地硬盘,它工作正常。仅当我尝试将文件保存到SharePoint文档库时,才会发生此错误。如果将OutputFormat更改为acFormatPDF以外的格式,则不再显示错误消息,但仍不会将任何文件写入SharePoint文档库 我是SharePoint网站的所有者,因此权限不是问题

我有一个MS Access 2010数据库,可以创建PDF,然后将文件保存到SharePoint 2010文档库。这已经运行了好几年了,但是现在我得到了一个2501运行时错误“输出操作被取消”

我可以将保存路径更改为本地硬盘,它工作正常。仅当我尝试将文件保存到SharePoint文档库时,才会发生此错误。如果将OutputFormat更改为acFormatPDF以外的格式,则不再显示错误消息,但仍不会将任何文件写入SharePoint文档库

我是SharePoint网站的所有者,因此权限不是问题

Const rootPath As String = "https://www.thisisnotreallythesharepointurl.com/"

DoCmd.OpenReport "Participant Certificate", acViewPreview, , strWhereCond, acWindowNormal

strReportName = strViewCity & "_" & strViewState & "_" & strLastname & "_" & strFirstname & ".pdf"
myPath = rootPath & strYear & "/Participant_Certificates/" & strReportName

DoCmd.OutputTo acOutputReport, "", acFormatPDF, myPath

DoCmd.Close acReport, "Participant Certificate"