Solid Edge Revision Manager Object Library
ImportDocumentsToServer Method
Specifies the number of documents and/or folders to import.
Specifies the documents and/or folders to import.
Specifies the location to which to import the specified documents and/or folders.
When the input is folders, TypeOfUpload is a member of the UploadType constant set that specifies whether to perform a deep or shallow upload. A deep upload includes subfolders; a shallow upload includes only the selected folder.
Member of the CheckInOptions constant set that specifies whether to upload and check in the documents, or to upload the documents without checking them in.
Description
This method imports to the server the documents and/or folders you specify.
Syntax
Visual Basic
Public Function ImportDocumentsToServer( _
   ByVal NumberOfDocumentsFoldersToImport As Long, _
   ByVal ListOfDocumentsFoldersToImport As Variant, _
   ByVal ImportLocation As String, _
   ByVal TypeOfUpload As UploadType, _
   ByVal CheckInOption As CheckInOptions _
) As Long
Parameters
NumberOfDocumentsFoldersToImport
Specifies the number of documents and/or folders to import.
ListOfDocumentsFoldersToImport
Specifies the documents and/or folders to import.
ImportLocation
Specifies the location to which to import the specified documents and/or folders.
TypeOfUpload
ValueDescription
DeepUploadTypeIncludes the selected folder and subfolders.
ShallowUploadTypeIncludes only the selected folder.
When the input is folders, TypeOfUpload is a member of the UploadType constant set that specifies whether to perform a deep or shallow upload. A deep upload includes subfolders; a shallow upload includes only the selected folder.
CheckInOption
ValueDescription
DoNotCheckInOption 
UploadAndCheckInOption 
Member of the CheckInOptions constant set that specifies whether to upload and check in the documents, or to upload the documents without checking them in.
Example
Imports RevisionManager
Imports System.Runtime.InteropServices

Module Example

    Sub Main()
        Dim objApplication As RevisionManager.Application = Nothing
        Dim objInsight As RevisionManager.Insight = Nothing
        Dim aListOfDocs(0) As String
        Dim strFolder As String

        Try
            ' Start Revision Manager.
            objApplication = New RevisionManager.Application

            ' Get reference to Insight object.
            objInsight = objApplication.Insight

            aListOfDocs(0) = "c:\temp\Summit_AddToLibrary.par"
            strFolder = "http://solidvm/Engineering/PreReleased/PreReleasedDocLib/"

            objInsight.ImportDocumentsToServer(aListOfDocs.Length, aListOfDocs, strFolder, UploadType.ShallowUploadType, CheckInOptions.UploadAndCheckInOption)
        Catch ex As Exception
            ' Write any errors to console.
            Console.WriteLine(ex.Message)
        Finally
            ' Release COM Objects.
            If Not (objInsight Is Nothing) Then
                Marshal.ReleaseComObject(objInsight)
                objInsight = Nothing
            End If

            If Not (objApplication Is Nothing) Then
                objApplication.Quit()
                Marshal.ReleaseComObject(objApplication)
                objApplication = Nothing
            End If
        End Try
    End Sub

End Module
See Also

Insight Object  | Insight Members

Send comments on this topic.