Problem to resolve it

Hi,
How to resolve the 2nd line below
        Configpath = Environment.CurrentDirectory & "\Config.xml"
        Dim ObjXml As New XmlTextReader(Configpath)
        ...

Open in new window

due to these?
Error	1	Type 'XmlTextReader' is not defined.	
Error	2	Name 'XmlNodeType' is not declared.	

Open in new window

LVL 11
HuaMin ChenSystem AnalystAsked:
Who is Participating?
 
Lokesh B RDeveloperCommented:
Hi,

whatever the version.

1. Right-Click on the References in your Project
2. Select Add Reference
3. Select System.Xml
4. Click Add/Ok
0
 
Lokesh B RDeveloperCommented:
Hi,

You need to add the System.Xml as Reference in your application.

  System.Xml.XmlTextReader ObjXml = new System.Xml.XmlTextReader(Configpath);

Open in new window


1. Right-Click on the References in your Project
2. Select Add-Reference
3. Under Framework tab select System.Xml
4. Click Add/Ok
0
 
HuaMin ChenSystem AnalystAuthor Commented:
But this VS 2008. After I have put your line from the above, I now have some other problem.
0
Cloud Class® Course: MCSA MCSE Windows Server 2012

This course teaches how to install and configure Windows Server 2012 R2.  It is the first step on your path to becoming a Microsoft Certified Solutions Expert (MCSE).

 
HuaMin ChenSystem AnalystAuthor Commented:
This is VS 2008.
0
 
Lokesh B RDeveloperCommented:
Hi,

are you in windows/web application?
0
 
Lokesh B RDeveloperCommented:
If it is web application you can follow the below steps

1. Right-Click on the References in your Project
2. Select Add-Reference
3. Under Framework tab select System.Xml
4. Click Add/Ok

If windows application, check this image

http://www.vbforums.com/attachment.php?s=a8c13e58a8d44c02cb6f300f6db774cc&attachmentid=51687&stc=1&d=1160786555
0
 
HuaMin ChenSystem AnalystAuthor Commented:
No, it is not Web application, but one VS 2008 Windows form project.
0
 
Amir OveisiSenior DeveloperCommented:
Hi
Witch version of .NET are you using?
To check that, you can right-click on your project in Solution Explorer and click on Properties. you can see Target Framework of your application.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.