C# Error CS1569 – Error writing to XML documentation file: {0}

C# Error

CS1569 – Error writing to XML documentation file: {0}

Reason for the Error & Solution

Error generating XML documentation file ‘Filename’ (‘reason’)

When attempting to write the XML documentation to the file named in the message, an error occurred for the reason specified. The reason may be something like "network drive not found," or "access denied." Often, the reason will suggest what needs to be done to correct the error. For example, if the error says "access denied," you would verify that you have write permission on the file.

Example 1

// 1569a.cs  
// compile with: /doc:CS1569.xml  
// post-build command: attrib +r CS1569.xml  
class Test  
{  
   /// <summary>Test.</summary>  
   public static void Main() {}  
}  

Example 2

The previous sample generated an .xml file that was then set to read only. This sample attempts to write to the same file. The following sample generates CS1569.

// CS1569.cs  
// compile with: /doc:CS1569.xml  
// CS1569 expected  
class Test  
{  
   /// <summary>Test.</summary>  
   public static void Main() {}  
}  

Leave A Reply

Your email address will not be published. Required fields are marked *

You May Also Like

C# Compiler Error CS0442 – ‘Property’: abstract properties cannot have private accessors Reason for the Error You’ll get this error...
This is a really simple one . Below is a simple example of an enum called “Designation” defined with the...
This blog post explain the usage of the Checked Block in .NET and how you can use them in Visual...