PrxMetaControlsAdd

Syntax

OpItemKey PrxMetaControlsAdd(string mon, PrxMetaControlsAddArg tArg)

Parameters

mon. Moniker for working with regular report controls.

tArg. Parameters for creating a control.

Description

The PrxMetaControlsAdd operation creates a regular report control.

Comments

To execute the operation, in the mon field specify regular report instance moniker with the !Controls postfix to work with controls, and in the tArg field specify parameters for creating a new control. The moniker can be obtained on executing the OpenPrxMeta operation.

The operation returns key of created control. To set parameters of control, use the SetPrxMeta operation.

Example

Below is the example of creating a regular report control. The request contains moniker for working with controls and key of the sheet, on which a control should be created. The response contains the key of the created control.

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">
<PrxMetaControlsAdd xmlns="http://www.fsight.ru/PP.SOM.Som">
  <mon xmlns="">S1!M!S!P1!Controls</mon>
<tArg xmlns="">
  <sheet>2</sheet>
  </tArg>
  </PrxMetaControlsAdd>
  </s:Body>
  </s:Envelope>

SOAP response:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
<PrxMetaControlsAddResult 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">
  <k xmlns="">2</k>
  </PrxMetaControlsAddResult>
  </soapenv:Body>
  </soapenv:Envelope>

JSON request:

{
"PrxMetaControlsAdd" :
{
"mon" : "S1!M!S!P1!Controls",
"tArg" :
{
"sheet" : "2"
}
}
}

JSON response:

{
"PrxMetaControlsAddResult" :
{
"k" : "2"
}
}
public static OpItemKey AddPrxControl(string moniker, uint sheetKey)
{
var somClient = new SomPortTypeClient(); //Proxy object for operation execution
//Operation execution parameters
var tAdd = new PrxMetaControlsAdd()
{
tArg = new PrxMetaControlsAddArg()
{
sheet = sheetKey
},
mon = moniker + "!Controls"
};
//Create a control
var result = somClient.PrxMetaControlsAdd(tAdd);
return result;
}

See also:

Working With Regular Reports