Opening Express Report for Edit

Below is the example of using the OpenEax operation to open an express report for edit. The request contains moniker of the object that is a report and a flag indicating whether the report must be opened for edit. The response contains moniker of opened express report instance. Any additional data is not obtained.

The C# example uses the FindObjectById function, which code is given in the Getting Object Description by Its Identifier section.

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">
<OpenEax xmlns="http://www.fsight.ru/PP.SOM.Som">
<tObject xmlns=" ">
  <id>S1!M!189</id>
  </tObject>
<tArg xmlns=" ">
<args>
  <openForEdit>true</openForEdit>
  </args>
  </tArg>
  </OpenEax>
  </s:Body>
  </s:Envelope>

SOAP response:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
<OpenEaxResult 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">
<id xmlns=" ">
  <id>S1!M!S!E12</id>
  </id>
  </OpenEaxResult>
  </soapenv:Body>
  </soapenv:Envelope>

JSON request:

{
 "OpenEax" : 
  {
   "tObject" : 
    {
     "id" : "S1!M!189"
    },
   "tArg" : 
    {
     "args" : 
      {
       "openForEdit" : "true",
       "storeObject" : "true"
      }
    }
  }
}

JSON response:

{
 "OpenEaxResult" : 
  {
   "id" : 
    {
     "id" : "S1!M!S!E2"
    }
  }
}
    public static OpenEaxResult OpenEaxForEdit(MbId mb, string eaxId)
{
var somClient = new SomPortTypeClient(); //Proxy object for operation execution
//Operation execution parameters
var tOpen = new OpenEax()
{
tArg = new OpenEaxArg()
{
args = new EaxOpenArgs()
{
openForEdit = true
}
},
//Create object moniker
tObject = new OdId() { id = mb.id + "!" + FindObjectById(mb, eaxId).k }
};
//Open express report
var result = somClient.OpenEax(tOpen);
return result;
}

See also:

OpenEax: Operation