[Mono-list] Newbie Problem with System.Xml

Jonathan Pryor jonpryor at vt.edu
Tue Dec 16 13:26:20 EST 2008


On Fri, 2008-12-12 at 01:46 -0800, Mucki wrote:
> i am learning C# in the Mono .Net environment and i tried some code around
> files. Of course i had a view on XML files and found the System.Xml class.
> 
> With the following code
> 
> using System;
> using System.IO;
> using System.Xml;
> 
> namespace XMLTest
> {...
> 
> i get an error: 
> 
> Main.cs(8,14): error CS0234: The type or namespace name `Xml' does not exist
> in the namespace `System'. Are you missing an assembly reference?

You need to reference the System.Xml.dll asssembly.

If building from the command line, use the -r:System.Xml.dll argument:

	gmcs foo.cs -r:System.Xml.dll

If using MonoDevelop, in the Solution Pane right-click References, then
click Edit References.  In the Packages tab, select the System.Xml
assembly, then click OK.

 - Jon




More information about the Mono-list mailing list