[Newbie] NAnt help?

  • Thread starter Thread starter Einar Høst
  • Start date Start date
E

Einar Høst

Hi,

Disclaimer:
I apologize if this is the wrong place for this type of question, but if so,
I don't know where the right place is and I'd be very grateful if someone
could point me in the right direction.

Question:
I'm trying to use nant to compile a project which provides database access.
The project compiles with no problems inside Visual Studio, but I'd like to
start using nant instead. However, the build fails when I try to use nant
with both my own attempt at creating a build file, and the one that
slingshot created for me. The complaint is the same in both cases: that
System.Data.SqlClient.SqlDataReader does not contain a definition for
"HasRows" - which it obviously does. So I'm thinking I'm missing something
vital regarding references, imports or namespaces, but I don't know what...

Any help would be greatly appreciated!

Regards,
Einar
 
Einar Høst said:
Disclaimer:
I apologize if this is the wrong place for this type of question, but if so,
I don't know where the right place is and I'd be very grateful if someone
could point me in the right direction.

Here is okay, or in one of the more "general" newsgroups - but the NAnt
mailing list would probably be the best place.
Question:
I'm trying to use nant to compile a project which provides database access.
The project compiles with no problems inside Visual Studio, but I'd like to
start using nant instead. However, the build fails when I try to use nant
with both my own attempt at creating a build file, and the one that
slingshot created for me. The complaint is the same in both cases: that
System.Data.SqlClient.SqlDataReader does not contain a definition for
"HasRows" - which it obviously does. So I'm thinking I'm missing something
vital regarding references, imports or namespaces, but I don't know what....

HasRows only appeared in V1.1 of the framework, so I suspect you're
currently building against V1.0. I haven't used NAnt, so I don't know
how easy it is to change what you're building against, but hopefully
that will help.
 
You're right - and it's easy to switch. I just needed to add the following
argument: /k:net-1.1 and everything went smoothly. Thanks!

- Einar
 
Back
Top