If you still use dotnet for legacy reasons for example in Business Central. You could encounter this issue in VS Code when building your app:
DotNet ‘XmlDocumentFragment’ is missing
This class is part of the System.Xml namespace and represents a lightweight object for tree insert operation. See all the info on Microsoft Docs: https://docs.microsoft.com/en-us/dotnet/api/system.xml.xmldocument.createdocumentfragment?view=netframework-4.8
In order to fix this in AL you need to do the following steps:
- Setup and configure Assembly Probing Paths in VS Code Workspace Settings
- Create a dotnet.al file in your AL Project. This file should now hold the following Json structure and contents:
dotnet { assembly("System.Xml") { Version = '4.0.0.0'; Culture = 'neutral'; PublicKeyToken = 'b77a5c561934e089'; type("System.Xml.XmlDocumentFragment"; "XmlDocumentFragment") { } } }