3.1.4.83 ApplyToRange

Performs different operations on a specified range based on the value of the id parameter.

The following is the WSDL port type specification of the ApplyToRange WSDL operation.

 <wsdl:operation name="ApplyToRange" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
   <wsdl:input wsaw:Action="http://schemas.microsoft.com/office/Excel/Server/WebServices/ExcelServerInternalService/ExcelServiceSoap/ApplyToRange" message="tns:ExcelServiceSoap_ApplyToRange_InputMessage" xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl"/>
   <wsdl:output wsaw:Action="http://schemas.microsoft.com/office/Excel/Server/WebServices/ExcelServerInternalService/ExcelServiceSoap/ApplyToRangeResponse" message="tns:ExcelServiceSoap_ApplyToRange_OutputMessage" xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl"/>
   <wsdl:fault wsaw:Action="http://schemas.microsoft.com/office/Excel/Server/WebServices/ExcelServerInternalService/ExcelServiceSoap/ApplyToRangeExcelServerMessageFault" name="ExcelServerMessageFault" message="tns:ExcelServiceSoap_ApplyToRange_ExcelServerMessageFault_FaultMessage" xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl"/>
 </wsdl:operation>

The protocol client sends an ExcelServiceSoap_ApplyToRange_InputMessage request message, and the protocol server responds with an ExcelServiceSoap_ApplyToRange_OutputMessage response message, as follows:

  1. The protocol client sends information identifying the operation that will to be performed in the id parameter and the range to which the operation will be applied to as specified by the range parameter.

  2. Based on the operation the protocol client requested:

    1. If the protocol client requested the merge operation, the protocol server creates a merged cell from the cells contained in the specified range.

    2. If the protocol client requested the clear operation, the protocol server deletes the cell contents of the cells in the specified range.

This operation is a state changing operation on the protocol server.

In the event of an application error on the protocol server during this operation, a SOAP fault is returned, as specified in section 2.2.2. The Id element of the ExcelServerMessage SHOULD<98> be one of the values specified in section 2.2.2.1 or any of the following values:

  • CannotEditPivotTable

  • CannotMergeCellsInTable

  • MergeCellsLoseData