locked
Error 80040154 executing 'syncAgent.Synchronize()' RRS feed

  • Question

  •  

    Hi everybody,

     

    I have a problem running the CTP2 under Windows XP SP2 and VS 2008 Professional Edition.

     

    I installed both the CTP2SyncServicesADO_x86.msi and the CTP2SyncSetup_x86.exe files, and tried the 'SharingAppDemo-Conflicts' demo.

     

    It worked relatively well, except for some compilation errors and execution exceptions, which I was easily able to correct or circumvent. But I was able to run at least one of the provided sync samples.

     

    The next day, because I had made some changes to the original samples and did not make a backup copy, I decided to reinstall both the Sync Setup and the Sync Services ADO files.

     

    Now, no matter what I try, including setting the platform target to X86 and the target framework to .Net Framework 3.5 on the test projects, I keep getting the following error:

     

     'Retrieving the COM class factory for component with CLSID {A7B3B4EE-925C-4D6C-B007-A4A6A0B09143) failed due to the following error: 80040154'.

     

    It occurs when the synchronization is tried, as shown by the line that is failing in the provided sample code:

     

    SyncOperationStatistics syncStats = syncAgent.Synchronize();  

     

    I tried reinstalling both setups and also cleaning the registry between the tries, but to no avail.

     

    This exact same error also occurs in every sample that came with the framework CTP2. It is clear that something went wrong, but I not able to figure out what is causing this problem.

     

    It looks like several other developers are having similar problems. Unfortunately, I was unable to find an answer.

     

    I need help to correct this problem to continue my development and testing. Any guidance will be very welcomed.

     

    PS: Just in case, I have noticed that my PC has the following components for the SQL CE 3.5 installed:

    • Microsoft SQL Server Compact 3.5 Design Tools ENU
    • Microsoft SQL Server Compact 3.5 for Devices ENU
    • Microsoft SQL Server Compact 3.5 SP1 Beta English
    • Microsoft SQL Server Compact 3.5 SP1 Beta Management Tools English

     

    Am I supposed to have the SP1 Beta installed?

     

    Thanks in advance,

     

    Eduardo Quintana

    Thursday, April 24, 2008 1:42 PM

Answers

  • Eduardo,

     

    There is one more step that is required to make the samples work and that is to create entries in the scope_info table on each peer.  These steps are listed in the setup\readme.txt file for each sample.  Simply open demo.sql and execute the statements under the "Configure scope members" heading at the top of the file to get started. 

     

    Also, the ColumnMapping sample also does table mapping, so on peer1 the table is called "ordertable" to show that peers can specify their own schema.  The .sql files in the setup dir for the ColumnMapping sample will reflect this.

     

    Hope this helps.

     

    Regards,

    Phil

     

    Monday, May 12, 2008 9:33 PM

All replies

  • Hi Eduardo,

     

    I have not been able to reproduce your issue.

     

    Could you please try the following steps to try to narrow down the problem?

     

    If the Microsoft Sync Framework installation is successful, you should see the following entries under "Add Remove Programs":
           - "Microsoft Sync Framework Runtime v1.0 CTP2 x86"
           - "Microsoft Sync Framework SDK v1.0 CTP2 x86"
           - "Microsoft Sync Framework Services v1.0 CTP2 x86"
           - "Microsoft Sync Services for ADO .Net v2.0 CTP2 x86"

     

    If the installation looks OK, you may want to check in VS that not only the "Configuration" but also the "Platform target"
    is set to x86 on the 'SharingAppDemo-Conflicts' project (it is easy to reset it by mistake).

     

    If this seems OK too, just to be sure this is not a VS configuration issue, you may want to install the 64-bit setup and try running the non-ADO samples again.

     

    I hope this helps.

     

     

     

     

    Saturday, April 26, 2008 12:50 AM
  • Dear Jeremie,

     

    Thanks for your help.

     

    I've been away from my office for a few days, but now I am back to this project.

     

    I verified my installed programs and only the "Microsoft Sync Framework SDK v1.0 CTP2 x86" item is not there.

     

    I tried to find an installation setup for it in the Microsoft Sync Framework site, but there were no one there.

     

    After removing and reinstalling the only two installation files available in the site, namely "CTP2SyncServicesADO_x86.msi" and "CTP2SyncSetup_x86.exe", the situation didn't change.

     

    If it is required to allow me to continue testing the Sync Framework, would you please send me a link to download the appropriate setup file?

     

    Thanks in advance,

     

    Eduardo Quintana

    Wednesday, May 7, 2008 12:56 PM
  •  

    Eduardo,

     

    I think the problem is that your installation of the Sync Framework runtime is no longer correct.  Since "Microsoft Sync Framework Runtime v1.0 CTP2 x86" appears in Add/Remove programs you should be able to repair it by using the Change button and then selecting the repair option.

     

    If this doesn't work you should try removing all the Sync Framework applications from Add/Remove programs.  Then reinstall using CTP2SyncSetup_x86.exe and CTP2SyncServicesADO_x86.msi.

     

    CTP2SyncSetup_x86.exe is really only an installer so it won't repair or uninstall the Sync Framework Runtime, this has to be done in Add/Remove programs.

     

    Thanks,

    Paul

    Thursday, May 8, 2008 4:59 PM
  • Dear Paul,

     

    The reinstallation of both programs solved the original problem. But, when I try the 'Column Mapping' or the 'Conflicts' samples, besides the wrong reference to the 'Microsoft.Synchonization.Data' dll (it should be 2.0, but it is referencing 1.0), and the reference to a non-existing table in the Peer1 database (the code uses the table named 'ordertable', but the correct table name is 'orders'), I still cannot run the samples because I am getting the following error:

     

    'Missing output value for parameter 'sync_scope_id' while executing SelectScopeInfoCommand command.'

     

    I traced the error in the source code to the following line:

     

    SyncOperationStatistics syncStats = syncAgent.Synchronize();

     

    in the following method of the SyncForm.cs form: 

     

    private void buttonSynchronize_Click(object sender, EventArgs e)

     

    As the problem is internal to the public class SyncOrchestrator, member of the Microsoft.Syncronization dll, there is little I can do to resolve this issue without your support.

     

    Could you please help me here?

     

    PS: Is there any chance you could send me updated samples?

     

    Regards,

     

    Eduardo Quintana

    Friday, May 9, 2008 6:23 PM
  • Eduardo,

     

    There is one more step that is required to make the samples work and that is to create entries in the scope_info table on each peer.  These steps are listed in the setup\readme.txt file for each sample.  Simply open demo.sql and execute the statements under the "Configure scope members" heading at the top of the file to get started. 

     

    Also, the ColumnMapping sample also does table mapping, so on peer1 the table is called "ordertable" to show that peers can specify their own schema.  The .sql files in the setup dir for the ColumnMapping sample will reflect this.

     

    Hope this helps.

     

    Regards,

    Phil

     

    Monday, May 12, 2008 9:33 PM
  • Hi there.

    I was getting the same error 'Missing output value for parameter 'sync_scope_id' while executing SelectScopeInfoCommand command.' but found that it is just a (cryptic?) way of saying that there is no record in the sync scope table with a scope_name as specified by the SyncProvider.ScopeName property value.

    Have a look at what the ScopeName is, then just add an entry to both your local and remote peer's scope table, using the same scope name and the same UID for both (just generate a UID in Visual Studio and use this in both tables).

    Then it should get you past this error.

    Regards,
    Paul.
    Thursday, July 9, 2009 11:11 AM