locked
Method not found: 'System.String System.Data.SqlServerCe.SqlCeType.get_DataType()' RRS feed

  • Question

  • I'm getting the below error.  I have switched to the ADO.NET 2.0 DLLs and the Sync Framework 1.0 DLL.  Everything compiles (had a compile error on another thread), but when I call MyBase.Synchronize() the following error occurs.  All the code worked with using Sync Services for ADO.NET 1.0, but trying to test in 2.0

     

    References:

    • Microsoft.Synchronization.Data (Runtime Version: v2.0.50727)
    • Microsoft.Synchronization.Data.Server (Runtime Version: v2.0.50727)
    • Microsoft.Synchronization.Data.SqlServerCe (Runtime Version: v2.0.50727)

     

    System.MissingMethodException occurred
      Message="Method not found: 'System.String System.Data.SqlServerCe.SqlCeType.get_DataType()'."
      Source="Microsoft.Synchronization.Data.SqlServerCe"
      StackTrace:
           at Microsoft.Synchronization.Data.SqlServerCe.SqlCeDatatypeMapping.GetColumnDefinition(SyncSchema schema, String tableName, String columnName)    at Microsoft.Synchronization.Data.SqlServerCe.SqlCeClientSyncProvider.BuildCreateCommand(SyncSchema syncSchema, SyncTable syncTable)    at Microsoft.Synchronization.Data.SqlServerCe.SqlCeClientSyncProvider.CreateOcsTable(String fmtTableName, Boolean createTable, SyncTable syncTable, SyncSchema syncSchema, SqlCeCommand cmdUtil)    at Microsoft.Synchronization.Data.SqlServerCe.SqlCeClientSyncProvider.CreateSchema(SyncTable syncTable, SyncSchema syncSchema)    at Microsoft.Synchronization.SyncAgent.InitClientSchema()    at Microsoft.Synchronization.SyncAgent.DataSynchronize()    at Microsoft.Synchronization.SyncAgent.Synchronize()    at TestClient.Sync.Client.OrderSyncAgent.Synchronize(Boolean ReThrowExceptions) in C:\TestClient\TestClient.Sync.Client\Sync Classes\OrderSyncAgent.vb:line 424
      InnerException:

    • Moved by Max Wang_1983 Friday, April 22, 2011 7:03 PM forum consolidation (From:SyncFx - Microsoft Sync Framework Database Providers [ReadOnly])
    Tuesday, July 1, 2008 8:35 PM

Answers

  • Adam-

     

    In the v2.0 DLLs, the changes were made to the SqlCeClientSyncProvider that require a newer version of the SQL CE runtime.  You can download it from here:

     

    http://www.microsoft.com/downloads/details.aspx?FamilyID=68539FAE-CF03-4C3B-AEDA-769CC205FE5F&displaylang=en

     

    This update is also delivered as part of the VS 2008 SP1 Beta and the SQL Server 2008 CTP.  This should resolve the issue you are seeing, the final version of the ADO.NET 2.0 DLLs will have a much more informative error message when this issue occurs and the CE runtime version is below what is expected.

     

    Thanks!

    Wednesday, July 2, 2008 3:47 PM

All replies

  • Adam-

     

    In the v2.0 DLLs, the changes were made to the SqlCeClientSyncProvider that require a newer version of the SQL CE runtime.  You can download it from here:

     

    http://www.microsoft.com/downloads/details.aspx?FamilyID=68539FAE-CF03-4C3B-AEDA-769CC205FE5F&displaylang=en

     

    This update is also delivered as part of the VS 2008 SP1 Beta and the SQL Server 2008 CTP.  This should resolve the issue you are seeing, the final version of the ADO.NET 2.0 DLLs will have a much more informative error message when this issue occurs and the CE runtime version is below what is expected.

     

    Thanks!

    Wednesday, July 2, 2008 3:47 PM
  • Thanks again Phil.

     

    Everything appears to be working.

     

    Just a summary in case anyone else reads this.  To upgrade from Sync Services ADO.NET 1.0 to the 2.0 (from the SQL 2008 RC0 disk) here is what I installed. 

     

    • Microsoft SQL Server Compact 3.5 SP1 Beta and Synchronization Services for ADO.Net v1.0 SP1 Beta
      http://www.microsoft.com/downloads/details.aspx?FamilyID=68539FAE-CF03-4C3B-AEDA-769CC205FE5F&displaylang=en
    • Synchronization.msi (Install from SQL 2008 RC0 disk)
    • SyncServicesADO.msi (Install from SQL 2008 RC0 disk)
    • I had to delete my 1.0 references and add the 2.0 references from C:\Program Files\Microsoft Sync Framework\....
    • I also had to add a reference to Microsoft.Syncronization which I did not have before.
    • I had to change my SyncException catch block to use Microsoft.Synchronization.Data.DataSyncException.

     

     

     

     


     

     

     

    Wednesday, July 2, 2008 7:09 PM
  • Adam,

    Glad you are up and running again and thanks for the summary post, that will be helpful for others.
    Wednesday, July 2, 2008 7:23 PM