Raise error System.Data.DataRowView'

Topics: Customizing Orchard
Aug 13, 2011 at 5:24 PM

Hi,

My view raise this error. I have reference System.data version 4. Why this error come

 

e:\Arruni\Arruni\Orchard.Web\Modules\PAM.Subscriber\Views\Admin\Index.cshtml(63): error CS0012: The type 'System.Data.DataRowView' is defined in an assembly that is not referenced. You must add a reference to assembly 'System.Data, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'.

Coordinator
Aug 14, 2011 at 5:05 PM

Never seen this one. Are you using ADO.NET directly ? What for ?

Apr 3, 2012 at 12:37 PM

If anyone else runs into this, add the following in your module's Web.config system.web / compilation / assemblies section:

<add assembly="System.Data, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/>

And it should be solved :)

Mar 18, 2013 at 12:20 PM
Hi i am using a app.config file for unit testing some *.cs classes and i have specified a connection string and a new excel data source that is used for my test purposes i am getting the error

Error 13 The type 'System.Data.DataRow' is defined in an assembly that is not referenced. You must add a reference to assembly 'System.Data, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'. D:\Visu\Develpement\WellsFargo Projects\Bangalore\IFP\VMSTestProject\VMSTestProject\VMSVisitRequestTest.cs 30 13 VMSTestProject

where should i be adding this line in my app/config file?
Please help me i am new to this.
Mar 18, 2013 at 12:27 PM
Hi i am using a app.config file for unit testing some *.cs classes and i have specified a connection string and a new excel data source that is used for my test purposes i am getting the error

Error 13 The type 'System.Data.DataRow' is defined in an assembly that is not referenced. You must add a reference to assembly 'System.Data, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'. D:\Visu\Develpement\WellsFargo Projects\Bangalore\IFP\VMSTestProject\VMSTestProject\VMSVisitRequestTest.cs 30 13 VMSTestProject

where should i be adding this line in my app/config file?
Please help me i am new to this.
Developer
Mar 19, 2013 at 12:37 AM
Perhaps you should add a reference to the assembly via the References node in your unit test project and the project under test?