1

we have created a feature ,which have got 2 application pages. one is to activate the user control and the other one is for database configuration,for the database configuration the user have to give the .mdf and .ldf files to restore the database. For the restoration of database we have used microsoft.sqlserver.replication.dll, the feature is working fine, but when we deploy it on any other machine, at the time of activation it gives error, and the error is: Error: Cannot add the specified assembly to the global assembly cache: Microsoft.SqlServer.Replication.dll. The feature is working fine with windows server 2008 but its giving the mention error with windows server 2003 .. any idea? Does anyone know how to solve this?

Thanks

SAAD

Saad
  • 1,312
  • 5
  • 17
  • 40
  • Is the DLL depending on a newer version of the .NET framework than you have installed? – Yuliy Apr 13 '10 at 07:32
  • no... its not depending on newer verison – Saad Apr 13 '10 at 07:50
  • The feature is working fine with windows server 2008 but its giving the mention error with windows server 2003 .. any idea? – Saad Apr 13 '10 at 12:46
  • We deploy the feature usign WSPBuilder.yes the Microsoft.SqlServer.Replication.dll is inside the wsp file. – Saad Apr 14 '10 at 04:34
  • FeatureActivated and FeatureDeactivating – Saad Apr 14 '10 at 04:37
  • yes it is. At the time of feature activation the setup GAC this assembly and add safe entry to web.config, and copy some user control to the virtualdirectories/port# and do some updation in the web.config. – Saad Apr 14 '10 at 09:36
  • our feature contain an application page, which use to restore database from .mdf file , for the restoration of file sqlserver.replication.dll is required,so this dll is the dependency – Saad Apr 14 '10 at 11:04
  • This assembly in already in the GAC. i m using WSPBuilder for creating feature, when we made deployment package ,wspbuilder itself add this dll in the .wsp file with safe control entry in the manifest.xml file. – Saad Apr 14 '10 at 13:30
  • No there is no such file that indicates to put the Microsoft.sqlserver.Replication.dll in GAC – Saad Apr 15 '10 at 10:59
  • @sbtahir I have no idea why the Replication assembly gets included in the WSP package. Here are my ideas: 1. Make sure you are using latest version of WSPBuilder. 2. Try to set `Copy Local` to `false` for the Replication reference in your project (as far as I know, WSPBuilder puts into the package all the assemblies in find in the `bin` folder). 3. Try to exclude the Replication assembly from the WSP package - this http://wspbuilder.codeplex.com/Thread/View.aspx?ThreadId=26455 may help. – Marek Grzenkowicz Apr 16 '10 at 08:50
  • i deployed the solution on virtual pc with windows 2003 and its work fine. – Saad Apr 16 '10 at 11:28
  • @sbtahir It's possible that you simple don't have some permission necessary to add anything to GAC on the 1st Windows 2003 server. However, I still think that you should modify the project so the Replication assembly is not placed in the WSP package. – Marek Grzenkowicz Apr 16 '10 at 13:30

0 Answers0