VB.NET with ADO.NET compilation error.

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I am using the command line to create a VB.NET and ADO.NET Application.
But Imports System.Data and Imports System.Data.SqlClient cannot be found
during compliation.

Can anyone show me how to setup the enviroment?
 
I am using the command line to create a VB.NET and ADO.NET
Application. But Imports System.Data and Imports System.Data.SqlClient
cannot be found during compliation.

Can anyone show me how to setup the enviroment?

It would be helpful to see the command line args your using but since I
can't I'll point out something you might not be aware of,

When compiling from the command line, you must explicitly reference the
Microsoft Visual Basic Run-Time Library through the /reference compiler
option. eg., vbc /reference:Microsoft.VisualBasic.dll MyFile.vb
This article can be found:http://msdn.microsoft.com/library/default.asp?
url=/library/en-us/vblr7/html/vaconvbcompileroptions.asp

If it not working in the IDE then you need to add a reference to them. In
the solution explorer right click on your project and select Add Reference.
In the dialog box select System.Data *I THINK* this needs to be done for
EACH project if its not all ready there.

Let me know,
MP
 
I look at it before, but I don't know how to add the reference under command
line.
Can you give me more information on it?
 
Especially for ADO.NET, How can I add the reference under command line

http://msdn.microsoft.com/library/default.asp?url=/library/en-
us/vblr7/html/vaconvbcompileroptions.asp

There is no command line for ADO. Your either using vb,c#,c++,j# or some
other language. The article above shows you how to use the command line to
compile with vbc.

You need to include much more info then your previous posts if you want a
good answer. I still don't know if you've even got this program running in
the IDE yet. If not, then problem is there, not the command line.
Otherwise, if it is running in the IDE then yes, you need help at the
command line.

But since I'm not a mind reader...

MP
 
Back
Top