0

I tried to create a visual web part and publish it to SharePoint online:

I created a visual web part at local using SharePoint server 2016 and to publish to SharePoint online, I selected "Sandboxed Solutions".

enter image description here

I tried to run test at local and publish to SP Online, but both throws errors:

$Resources:core,ImportErrorMessage;

enter image description here

enter image description here

Can I create visual web part for SharePoint online in SharePoint 2016?

1 Answer 1

1

Code based sandbox solutions contain server-side code and the solution contains .Net assembly file (.dll). SharePoint online doesnot support Code-based sandbox solutions.

You could transform sandbox solutions to the SharePoint Add-in model:

https://docs.microsoft.com/en-us/sharepoint/dev/solution-guidance/sandbox-solution-transformation-guidance

4
  • But sharepoint add-in is a application or a page, it is not a part of page. can't create a webpart for SP Online by visual studio?
    – D T
    Jan 12, 2021 at 8:47
  • For SharePoint online, we can only create client-side web parts: docs.microsoft.com/en-us/sharepoint/dev/spfx/web-parts/… Jan 12, 2021 at 9:03
  • Thank you, your information.
    – D T
    Jan 12, 2021 at 9:43
  • If my answer helps you, please accept it :) Jan 13, 2021 at 1:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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