tags:

views:

13

answers:

1

i am new to subsonic, i am trying to use subsonic 3.0

i followed every steps to set up subsonic

Problem is i am trying to use subsonic3.0 in a web project (with dotnetnuke) to create a dll file. so i can re use in other projects in the same solution.

when i try to build i got error with one of my old table column,

Error 5 Cannot implicitly convert type 'string' to 'int?' C:\WebProjects\subsonicTest\App_Data\ActiveRecord.cs 14035 32 subsonicTest

Error 25 The best overloaded method match for 'string.IsNullOrEmpty(string)' has some invalid arguments C:\WebProjects\subsonicTest\App_Data\ActiveRecord.cs 47752 16 subsonicTest

Error 31 'dnn3.Data.PackageType' does not contain a definition for 'PackageType' and no extension method 'PackageType' accepting a first argument of type 'dnn3.Data.PackageType' could be found (are you missing a using directive or an assembly reference?) C:\WebProjects\subsonicTest\App_Data\ActiveRecord.cs 48082 25 subsonicTest

Could you please give me an idea how to solve.

thanks shah

+1  A: 

Obviously, the types of some columns are wrong. Probably you changed table definitions in the database and didn't update all the code generated by Subsonic.
Try re-generating the code (Solution Explorer, right click on the file, Run custom tool).

If you have manually written something using the generated code, check that your code relies on correct type definitions after those definitions are updated.

If this doesn't help, try looking at the exact lines with errors. Edit your question to include these lines so that someone can try to help without having to guess what is going on there.

VladV
Thanks for your quick reply. yea your right. i have fixed rest of the error. but i got one existing error which says. dnn3.Data.PackageType' does not contain a definition for 'PackageType' and no extension method 'PackageType' accepting a first argument of type 'dnn3.Data.PackageType' could be found (are you missing a using directive or an assembly reference?). Here dnn3 is my connectionStrings name.am i missing any assembly reference?.
shah
That's unlikely since all the types involved are defined in your code. Probably you have an object of type dnn3.Data.PackageType and try to call a method PackageType on this object. No scuh method exists, so compiler throws an error. Depending on what you are trying to do, you should iether create this method, or change the code so it doesn't try to call it.
VladV
thanks for your help
shah