locked
Problem with example from the ctp1 RRS feed

  • Question

  •  

    Hi,

     

    i had a problem with this example (@ the bottom). This is for the ctp1, I mean and I'm downloaded -> installed the ctp2 version.

     

    after some customizations, there is only one problem, the agent

     

    i found no agent-class in synchronisation/synchronisation.files.dlls, but i need the agent to synchronize?? or the synchronize method can be found in an other class, since the ctp2

     

    greetz bAsTi

    Friday, June 13, 2008 1:20 PM

Answers

  •  

    Hi,

     

    Microsoft.Synchronization.dll should have the agent - SyncOrchestrator. You dont need to reference the SyncToy.

    You can instantiate the syncorchestrator, set the direction of sync, point to the providers and call agent.synchronize()

     

    Please do look at the Sync101 samples - http://code.msdn.microsoft.com/Release/ProjectReleases.aspx?ProjectName=sync&ReleaseId=949

     

    Monday, June 16, 2008 8:42 PM
  • I dont think you can sync a FTP directory with local dir. It has to be a remote share.

    Friday, June 20, 2008 6:51 AM
  • i solved problem alone and i could hit me always when the answer is so clear and easy and i can't see it ....

    ok, when i couldn't create the filesync.metadata, why i create it somewhere else... and as i looked at the constructor around the thousand times i saw that i can transfer the filesync.metadata-path ....

    anyway thx
    Wednesday, June 25, 2008 12:56 PM

All replies

  • ok,

     

    nobody has an idea.

     

    i'm found the synctoy-utility and tried to reference the SyncToyEngine.dll in my c#-project and it works!

     

    my question is, i believe that i can do much more with the framework, but are there more reasons to use the framework instead of the synctoy component(dll)??

     

    actually my sync job is a simply syncjob -> new files pasted in dir a, the job recognise it and copy the files in dir b

     

    and another question can i synchronize from a ftp dir to a local dir, with the synctoy???

    Monday, June 16, 2008 11:48 AM
  •  

    Hi,

     

    Microsoft.Synchronization.dll should have the agent - SyncOrchestrator. You dont need to reference the SyncToy.

    You can instantiate the syncorchestrator, set the direction of sync, point to the providers and call agent.synchronize()

     

    Please do look at the Sync101 samples - http://code.msdn.microsoft.com/Release/ProjectReleases.aspx?ProjectName=sync&ReleaseId=949

     

    Monday, June 16, 2008 8:42 PM
  •  

    Hi,

     

    ok thx, i found the agent, but where i can set the paths(source/target)?

    or gets the agent the paths from the metadatastore-files??

     

    edit:

    when i sync no files are synced and cause no error is thrown, i think that 2 other directorys synched

    Tuesday, June 17, 2008 2:37 PM
  • hello again,

    ok now i know what i want... Big Smile

    in the example in my first entry, a FileSyncProvider is used and afterwards delivered to the agent. cause the example is a ctp1 example and i use the ctp2, would i know how i can synchronize with the
    FileSyncProvider??

    than the
    FileSyncProvider is the answer to my prior question

    and sorry for my bad english, when someting is wrong, else forget it Big Smile !

    greetz bAsTi
    Wednesday, June 18, 2008 8:30 AM
  • Sorry, I did not completely understand your statements.

    Do you still have an issue or it is now resolved?

    Wednesday, June 18, 2008 3:30 PM
  • Edit: ok, i don't know why i tested it again with the agent, then it works perfect!!

    Before this i had call the agent from the microsoft.synchronisation.data.dll and there the propertys localprovider/remoteprovider don't accept a filesyncprovider and so my question was, with which class can i synchronize with the filesyncprovider, sorry for the problems!

    But I have another question: Can I synchronize a ftp directory with a local dir??
    Thursday, June 19, 2008 7:19 AM
  • I dont think you can sync a FTP directory with local dir. It has to be a remote share.

    Friday, June 20, 2008 6:51 AM
  • hi again,

    i know i'm annoying but i want sync a ftp-dir with a local and so downloaded me WebDrive binded the ftp-access as a drive and tested with System.IO.File.Create(path); if the drive works and it works!!!

    so but when I instance the filesyncprovider, normally the filesync.metadata file should be created, but instead the erro message: "SQL Server Compact Edition encountered problems when creating the database. [,,,,,]" appears.

    i know the rights to read/write are the error, but why i can create a file with the io - namespace??

    thx bAsTi

    edit:

    ok the other way around asked: knows someone which rights the sync process use? then seemingly the io.file.create method uses an another one...


    oh my god, i think my sentences are horror, for a native speaker Wink ....
    Monday, June 23, 2008 10:18 AM
  • i solved problem alone and i could hit me always when the answer is so clear and easy and i can't see it ....

    ok, when i couldn't create the filesync.metadata, why i create it somewhere else... and as i looked at the constructor around the thousand times i saw that i can transfer the filesync.metadata-path ....

    anyway thx
    Wednesday, June 25, 2008 12:56 PM