Contents
Setup your XML to SharerPoint connection
- Create your list in SharePoint, e.g. a custom list named XML.
- Go to List Settings > General Settings > Connect to external data source.
- Select the Layer2 Data Provider for XML as connection provider.
- Enter the following XPath settings as Select Statement:
SharePoint: How to display blog feed using XML Web Part?
- Move to SharePoint page you want to add your blog feed.
- Open this page in edit view and add new Web Part called XML Web Part.
- If Web Part is added to page then open it’s settings window.
- On the field XML Link insert your blog feed URL.
How do I read XML file from SharePoint library?
Read a file
- string strFileURL = “http://servername/sites/TestSite/TestLib/Text.xml “;
- WebClient webClient = new WebClient();
- webClient.Credentials = CredentialCache.DefaultCredentials.
- using (StreamReader reader = new StreamReader(webClient.OpenRead(strFileURL))
- {
- XDocument Xdoc = XDocument.Parse(reader.ReadToEnd());
- }
XML Web Part: SharePoint provides an out-of-the-box Webpart which essentially takes two inputs. XML and XSL file paths. You can learn more about the XML web part here.
When we call GetXDocument, it first looks to see whether an annotation of type XDocument exists on the OpenXmlPart. If the annotation exists, GetXDocument returns it. If the annotation doesn’t exist, the method populates an XDocument from the part, annotates the part, and then returns the new XDocument.
How to create a plain text document in SharePoint?
(Click Word Options on the Office menu; then, in the Word Options dialog box, select Show Developer Tab in Ribbon.) To insert a content control, select some text and then click the button in the Controls area of the Developer tab that creates a plain text content control, shown in Figure 5.
How to use Open XML in Microsoft Word?
Open XML content controls provide a facility in word-processing documents that allows you to delineate content and associate metadata with that content. To use content controls, you must enable the Developer tab in Microsoft Office Word 2007.