Omnitracker – import of data from Powershell

$objOTApp = New-Object -ComObject OTAut.OtApplication
$objOTSession = $objOTApp.MakeSession($strServerName, $strServerPort, $strLoginName, $strPassWd)
$objOTFolder = $objOTSession.GetRequestFolderByPath($strFolderName)
                  Do {
                        Start-Sleep -Seconds 2
                        Write-Host „Waiting for OT response…”
                        $objImport = $objOTFolder.MakeImport()
                        #$objImport                      
                    }
                    Until ($objImport.Datasource -eq „”)

#$objOTFolder.ImportDefinitions
Write-Host „Importing objects to Omnitracker”
$objImport.Datasource = $strFileName
$objImport.Run($ImportName)
$objImport
$objOTSession.Logoff()

Dodaj komentarz

Twój adres e-mail nie zostanie opublikowany. Wymagane pola są oznaczone *