1. Web service GetDatas

    Artikel: AN0002070Aktualisiert:
    Die vorgegebene Sprachenversion vom Artikeltext wird angezeigt, weil es kein Text von der ausgewählten Sprache und Version gibt.

    This method reads more records from a particular class or a query.

    Definition

    OGDataResult GetDatas(OGData filter)

    Set up of the object OGData for filtering is described at the object OGData.

    Example

    $ws = 'http://localhost:55668/OGService.asmx?WSDL'
    $source = New-WebServiceProxy -Uri $ws -UseDefaultCredential

    #reading variables from WebService
    $OGData = $source.GetType().Namespace + '.OGData'

    #creation of filter object
    $filter = New-Object($OGData)
    #$filter.Id = 100
    $filter.ParentType = 0

    #calling by means of class ID
    $filter.ParentId = 16

    #calling by means of code
    #$filter.ModelCode = 'mymodel'
    #$filter.ParentCode = 'myclass'

    #$filter.ReturnMetadata = 1
    #$filter.LanguageCode = 'cs-CZ'

    #calling method
    $objData = $source.GetDatas($filter)

    #enumeration of column collection of the given class record
    foreach($data in $objData.Datas)
    {
        foreach($item in $data.ColumnData)
        {
            #Key = column ID
            #Value = column value
            Write-Host $item.Key - $item.Value
        }
    }

×