Generate .app file for SharePoint Apps using MSBuild and Visual Studio 2015/2017
Check out Best Alternative to InfoPath -> Try Now
This SharePoint Apps tutorial, we will discuss, how to generate the .app file using MSBuild as well as from visual studio 2015/2017/2019.
You can use visual studio 2015/2017 to develop the SharePoint hosted apps or add-ins.
Generate SharePoint .app file using MSBuild
After developing the .app file, open the visual studio 2015 command prompt. Then run the command like below:
msbuild /t:Package “E:\Users\Administrator\Documents\Visual Studio 2015\Projects\MyFirstDemoAddin\MyFirstDemoSPAddin\MyFirstDemoSPAddin.csproj”
The command looks like below:
Once it is generated successfully, it will give a success message like below. It will generate the .app file inside the Debug folder like below:
E:\Users\Administrator\Documents\Visual Studio 2015\Projects\MyFirstDemoSPAddin\MyFirstDemoSPAddin\bin\Debug\app.publish\188.8.131.52
Generate SharePoint .app file from visual studio
We can also generate the SharePoint .app file from the Visual Studio itself.
Right-click on the project and then click on the Publish… button like below:
Then in the Publish screen click on Package the add-in like below:
After successfully generating the .app file it will open the folder containing the .app file.
You may like following SharePoint apps tutorials:
- Develop SharePoint workflows using visual studio as SharePoint hosted App
- Failed to get web title Error Access denied You do not have permission to perform this action or access this resource
- Error occurred in deployment step Install app for SharePoint Communication with the SharePoint server is canceled
- Error occurred in deployment step Retract Solution A communication error has occurred while invoking commands in SharePoint host process
- How to create provider hosted app in SharePoint Online step by step
- Skipping the uninstall step because the SharePoint Add-in is in an invalid state and cannot be uninstalled error in SharePoint hosted add-in
- SharePoint hosted add-in: Error. Access denied. You do not have permission to perform this action or access this resource
- SharePoint Hosted App: Get Data from Host Web
- SharePoint Online Develop SharePoint Hosted Add-in using Visual Studio 2015 Demo
- Error occurred in deployment step Install SharePoint Add-in Sideloading of apps is not enabled on this site
This tutorial, we discussed how to generate .app file for SharePoint Apps or add-ins using MSBuild and Visual Studio 2015/2017/2019.
SharePoint Online FREE Training
JOIN a FREE SharePoint Video Course (3 Part Video Series)