Quantcast
Channel: All Revit API Forum posts
Viewing all articles
Browse latest Browse all 66672

Cannot get ClearTransmitted to work in Revit 2017

$
0
0

Hello,

 

I need to re-save as central many central files, the following code almost works but it is not saving each file as a new central. I still get the transmitted from another location message when I open the central files.

 

                    Dim objOpenOptions As New OpenOptions
                    objOpenOptions.DetachFromCentralOption = DetachFromCentralOption.DetachAndPreserveWorksets
                    Dim objModelPath As ModelPath = ModelPathUtils.ConvertUserVisiblePathToModelPath(strFullFileName)
                    Dim openDocument As Document = objApp.OpenDocumentFile(objModelPath, objOpenOptions)
                    Dim objSaveAsOptions As New SaveAsOptions()
                    objSaveAsOptions.OverwriteExistingFile = True
                    objSaveAsOptions.Compact = True
                    Dim objWorksharingSaveAsOptions As New WorksharingSaveAsOptions()
                    objWorksharingSaveAsOptions.SaveAsCentral = True
                    objWorksharingSaveAsOptions.OpenWorksetsDefault = SimpleWorksetConfiguration.AllWorksets
                    objWorksharingSaveAsOptions.ClearTransmitted = True
                    objSaveAsOptions.SetWorksharingOptions(objWorksharingSaveAsOptions)
                    openDocument.SaveAs(objModelPath, objSaveAsOptions)
                    openDocument.Close(False)

Any ideas?

Kind Regards

David

 


Viewing all articles
Browse latest Browse all 66672

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>