You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/transform/modernize-userinterface-site-pages-dotnet.md
+57Lines changed: 57 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -153,6 +153,63 @@ using (var cc = am.GetSharePointOnlineAuthenticatedContextTenant(siteUrl, userNa
153
153
> [!Note]
154
154
> Not all web parts lend themselves well for a cross site transfer, check the **Cross site support** column in [web part transformation list](modernize-userinterface-site-pages-webparts.md) to learn more.
155
155
156
+
157
+
### Read publishing page in on-premises SharePoint and create the modern page in SharePoint Online (as of June 2019 release, version 1.0.1906.*)
158
+
159
+
When you want to bring over your classic on-premises publishing portals you could first move the complete portal from on-premises to a classic portal in SharePoint Online and then do the modernization work. However, often it's easier to directly read the classic publishing page from your SharePoint on-premises portal and create the modern version in SharePoint Online.
Console.WriteLine($"Page {page.FieldValues["FileLeafRef"]} could not be transformed: {ex.Message}");
198
+
}
199
+
}
200
+
201
+
// Flush the log data
202
+
pageTransformator.FlushObservers();
203
+
}
204
+
}
205
+
```
206
+
207
+
> [!NOTE]
208
+
> - This feature is still in preview in the June 2019 release...it should support SharePoint 2013, 2016 and 2019
209
+
> - It's important to run your code on a machine that is able to connect to both the on-premises SharePoint server as the SharePoint Online environment
210
+
> - There (currently) is no user mapping feature, hence item level permissions are not copied over from the on-premises publishing page to the SharePoint Online modern page
211
+
> - This approach can also be used for page transformation across tenants (whenever that would make sense)
212
+
156
213
### I want to use the logging features (as of April 2019 release, version 1.0.1904.*)
157
214
158
215
By default there are three possible log observers (Console, Markdown and MarkdownToSharePoint). The latter two create an MD based report and put them on disk or in SharePoint as a client side page, whereas the first one simply outputs console messages. Below sample shows how you can use the loggers from .Net:
### Read publishing page in on-premises SharePoint and create the modern page in SharePoint Online (as of June 2019 release, version 3.10.1906.*)
101
+
102
+
When you want to bring over your classic on-premises publishing portals you could first move the complete portal from on-premises to a classic portal in SharePoint Online and then do the modernization work. However, often it's easier to directly read the classic publishing page from your SharePoint on-premises portal and create the modern version in SharePoint Online. To do this you need to use PnP PowerShell for SharePoint Online to connect to your on-premises portal like shown in below script:
103
+
104
+
```Powershell
105
+
# Setup connection the target site - must be SPO and must be a modern site
# Convert a classic page living in the on-premises portal to a modern page in SharePoint Online. Dependent images and videos are copied as well from on-premises to online during this process.
> - This feature is still in preview in the June 2019 release...it should support SharePoint 2013, 2016 and 2019
117
+
> - It's important to use the SharePoint Online PnP PowerShell version, the machine running the PowerShell script needs to be able to connect to both the on-premises SharePoint server as the SharePoint Online environment
118
+
> - There (currently) is no user mapping feature, hence item level permissions are not copied over from the on-premises publishing page to the SharePoint Online modern page
119
+
> - This approach can also be used for page transformation across tenants (whenever that would make sense)
120
+
100
121
### Use the logging features (as of June 2019 release, version 3.10.1906.*)
0 commit comments