1

After creating a SharePoint app project, there is no "default.aspx.cs" code behind file. Only default.aspx

My APP is SharePoint-hosted. Is that the reason? Can I code freely in a SharePoint-hosted APP with C# code? If not, what is the best alternative?

2

Can I code freely in a SharePoint-hosted APP with C# code?

As short answer NO, SharePoint hosted APPis Written using JavaScript, HTML, and CSS , no Server Side code.

If not, what is the best alternative?

To can use Server side code you should use Cloud-hosted APP

  • Provider-hosted
  • Autohosted (is deprecated).

For more details check Choose patterns for developing and hosting your SharePoint Add-in

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.