J
J.Edwards
Hi,
I am using form inheritance in VS2005 professional and all was going well -
I used the "DesktopCompatible(true)" workaround to get the designer behaving
correctly.
However, when I added a reference to System.Data.SqlServerCe it now causes
this error on build:
Error 1 genasm.exe(1) : error There was an error initializing
MyProject.MySqlCeDatabase. Type 'System.Data.SqlServerCe.SqlCeConnection,
System.Data.SqlServerCe, Version=3.0.3600.0, Culture=neutral,
PublicKeyToken=3be235df1c8d2ad3, Retargetable=Yes' was loaded in the
ReflectionOnly context but the AssemblyBuilder was not created as
AssemblyBuilderAccess.ReflectionOnly. ClassLibrary1
"MySqlCeDatabase" is just a wrapper I've built around the sql server ce
stuff to make it easier to work with.
It's a fairly large class library and I thought it must be some of the code
in it somewhere, so to try and reproduce the problem I've created a new
class library from scratch and added all of the same files and references -
it compiled perfectly with all files until I added the
"DesktopCompatible(true)" workaround (i.e. through the class designer). Once
that was done the error happened and I can't seem to "undo" that change -
I've removed the attribute and saved, and deleted the class diagram file
completely and the error happens still - modifying the class diagram must
change some code somewhere, but I can't find it.
NOTE: it's not the "DesktopCompatible(true)" workaround by itself causing
the problem - it's the combination of it and System.Data.SqlServerCe
reference.
Anyhow, does anyone know what I can do to get around this - I would really
like to have designer support for inherited forms working happily with an
sql server db otherwise what's the point of vs2005? actually there are
other points, but that is not the point!
I am using form inheritance in VS2005 professional and all was going well -
I used the "DesktopCompatible(true)" workaround to get the designer behaving
correctly.
However, when I added a reference to System.Data.SqlServerCe it now causes
this error on build:
Error 1 genasm.exe(1) : error There was an error initializing
MyProject.MySqlCeDatabase. Type 'System.Data.SqlServerCe.SqlCeConnection,
System.Data.SqlServerCe, Version=3.0.3600.0, Culture=neutral,
PublicKeyToken=3be235df1c8d2ad3, Retargetable=Yes' was loaded in the
ReflectionOnly context but the AssemblyBuilder was not created as
AssemblyBuilderAccess.ReflectionOnly. ClassLibrary1
"MySqlCeDatabase" is just a wrapper I've built around the sql server ce
stuff to make it easier to work with.
It's a fairly large class library and I thought it must be some of the code
in it somewhere, so to try and reproduce the problem I've created a new
class library from scratch and added all of the same files and references -
it compiled perfectly with all files until I added the
"DesktopCompatible(true)" workaround (i.e. through the class designer). Once
that was done the error happened and I can't seem to "undo" that change -
I've removed the attribute and saved, and deleted the class diagram file
completely and the error happens still - modifying the class diagram must
change some code somewhere, but I can't find it.
NOTE: it's not the "DesktopCompatible(true)" workaround by itself causing
the problem - it's the combination of it and System.Data.SqlServerCe
reference.
Anyhow, does anyone know what I can do to get around this - I would really
like to have designer support for inherited forms working happily with an
sql server db otherwise what's the point of vs2005? actually there are
other points, but that is not the point!