SetDataAreaGridMetaData

Syntax

bool SetDataAreaGridMetaData(string mon, DataAreaGrid tArg)

Parameters

mon. Moniker of the Table visualizer.

tArg. Parameters of the Table visualizer that should be set.

Description

The SetDataAreaGridMetaData operation changes metadata of the Table visualizer.

Comments

The operation is used to work with the Table visualizer that displays data of analytical data area.

To execute the operation, in the mon field specify regular report instance moniker with the !DataArea!DataSources!'source key'!DataSourceSlices!'slice key'!Views!'table key' postfix, and in the tArg field specify values to be changed. The moniker can be obtained on executing the OpenPrxMeta operation.

The operation returns True if changes are applied successfully.

Example

Below is the example of enabling sorting in table. The request contains table moniker and the fields that determine whether sorting should be enabled. The response contains whether sorting is successfully enabled.

SOAP request:

<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
<s:Body xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<SetDataAreaGridMetaData xmlns="http://www.fsight.ru/PP.SOM.Som">
  <mon xmlns="">S1!M!S!P1!DataArea!DataSources!1!DataSourceSlices!1!Views!4</mon>
<tArg xmlns="">
  <displayLeftHeaderSortIcons>true</displayLeftHeaderSortIcons>
  <displayTopHeaderSortIcons>true</displayTopHeaderSortIcons>
  </tArg>
  </SetDataAreaGridMetaData>
  </s:Body>
  </s:Envelope>

SOAP response:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
  <SetDataAreaGridMetaDataResult xmlns="http://www.fsight.ru/PP.SOM.Som" xmlns:q1="http://www.fsight.ru/PP.SOM.Som" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">1</SetDataAreaGridMetaDataResult>
  </soapenv:Body>
  </soapenv:Envelope>

JSON request:

{
"SetDataAreaGridMetaData" :
{
"mon" : "S1!M!S!P1!DataArea!DataSources!1!DataSourceSlices!1!Views!4",
"tArg" :
{
"displayLeftHeaderSortIcons" : "true",
"displayTopHeaderSortIcons" : "true"
}
}
}

JSON response:

{
"SetDataAreaGridMetaDataResult" : "1"
}
public static bool SetDataAreaGridMetaData(string moniker, uint sourceKey, uint sliceKey, uint viewKey)
{
var somClient = new SomPortTypeClient(); //Proxy object for operation execution
//Operation execution parameters
var tSet = new SetDataAreaGridMetaData()
{
tArg = new DataAreaGrid()
{
viewSettings = new EaxGridViewSettings()
{
leftSettings = new EaxGridHeaderSettings()
{
displaySortIcons = true,
},
topSettings = new EaxGridHeaderSettings()
{
displaySortIcons = true
}
}
},
mon = moniker + "!DataArea!DataSources!" + sourceKey.ToString() + "!DataSourceSlices!" + sliceKey.ToString() + "!Views!" + viewKey.ToString()
};
//Change table metadata
var result = somClient.SetDataAreaGridMetaData(tSet);
return result;
}

See also:

Working with Regular Reports