如何将单个部署的文件更新为先前部署的sharepoint应用程序包的一部分 [英] How to update a single deployed file as part of a previously deployed sharepoint app package

查看:86
本文介绍了如何将单个部署的文件更新为先前部署的sharepoint应用程序包的一部分的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

想象一下,我有一个Sharepoint托管的部署应用程序,存储在应用程序Web中,我在这个应用程序的文件结构中有一个文件说config.json。对于不同的部署,配置将有所不同。有没有办法访问这个
文件,修改它并将其重新上传回正确的位置,以便下次运行应用程序时它将获取新文件。

So imagine I have a Sharepoint-hosted deployed app, stored within the app web and I have a file say config.json somewhere within the file structure of this app. The configuration will be different for different deployments. Is there a way to access this file, modify it and reupload it back to the correct location such that the next time the application is run it will pick up the new file.

其次,以更一般的方式,如何通过Windows资源管理器查看已部署应用程序的文件结构。

Second, in a more general way how does one view the file structure of the deployed app, say via windows explorer.

第三,我了解文件存储在应用程序Web中(即我不知道如何通过正常的文件管理操作与之交互。

Third I understand that the files are stored within the app web (i.e. a sub web of the main site collection), I just do not know how this is interacted with via normal file management operations.

推荐答案

作为一种解决方法,我们可以将文件(例如:config.json)存储在主机Web文档库中,或者在app web中创建文档库并将文件存储在其中。

As a workaround, we can store the file(for example:config.json) in host web document library or create a document library in app web and store the file in it.

我建议将文件存储在主机网页中,因为管理方便。

I suggest to storing the file in host web because of the convenience of management.

然后,我们可以在app中访问该文件。

Then, we can access the file in app.

更多信息供您参考:

https://docs.microsoft.com/en-us/sharepoint/dev/sp -add-ins / access-sharepoint-data-from-add-ins-using-the-domain-library

祝你好运,

Lee Liu


这篇关于如何将单个部署的文件更新为先前部署的sharepoint应用程序包的一部分的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆