Hello All,
Want help to copy documents from one repository to another repository.
So, I did search for documents needed to be copied and want to copy them to another repository according to document metadata each document will be copied to different path in destination repository.
Thanks.
string serchParameters = "{[]:[Verified]=\"Yes\"} & {LF:LOOKIN=\""+br + @"\sample\""}"; RepositoryRegistration repository = new RepositoryRegistration("server", "reponame"); using (Session session = new Session()) { session.LogIn("username", "pasword", repository); Search lfSearch = new Search(session, serchParameters); SearchListingSettings settings = new SearchListingSettings(); settings.AddColumn(SystemColumn.Id); lfSearch.Run(); SearchResultListing searchResults = lfSearch.GetResultListing(settings); foreach (EntryListingRow item in searchResults) { Int32 docId = (Int32)item[SystemColumn.Id]; EntryInfo currentEntry = Entry.TryGetEntryInfo(docId,session); // copy each document to other repository }