TabRangePasteResult TabRangePaste(string mon, TabRangePasteArg tArg)
mon. Moniker for working with table cell range.
tArg. Parameters for pasting cell range.
The TabRangePaste operation pastes copied data to cell range.
The operation pastes the data to the cell range, which was copied or cut using the TabRangeCopy/TabRangeCut operations. To execute the operation, in the mon field specify moniker of regular report instance with the !Sheets!sheet key!range address postfix that determines a cell range, to which data is inserted. In the tArg field specify insert mode and inserted data.
The operation results in information about data insert results.
Below is the example of pasting the copied or cut cell range. The request contains moniker of the range, to which data is inserted, the stream with inserted data, and insert mode - text, formulas, and formatting. The response contains data insert result.
{
"TabRangePaste" :
{
"mon" : "MGKDPJABAJEGGOAELIOKBIDEHDDAAAGEAJBDEOOOILGAFOPC!M!S!PEBIIJIBBAJEGGOAEEAPOAFJCAOCEDKJEEIODGHNJHMCAIENH!Sheets!1!G0:H3",
"tArg" :
{
"data" :
{
"it" :
{
"@type" : "1",
"data" : "ewAAAAMAAAB4nN2UzQ3CMAyFX5z0Z58OgLpJuSAhcWIBypEtmIAZGAAxEhAndgmpEMfSWnLb2G7ir091d7+c4I0QzYrz2iGxGwp\/bbHHFmvsONTWQB+SPtUPi\/Pm2jTNKnXdxDy94Ytx7tDhEZ\/i4aYi3nd4zeQBygM2C5j0CNLI0ZAJONLXvPGU0SZ4tAw8ReN7qp4VPBOKuPifCdRTgZwQFKFoSg2QE2BMQNI4b8rNflbo9KBMpWI2KikfZSqVQuAmVqmkXyrpt9fJPVbJSgM635WxwiJGhcX7J0slrAUvSDyhhA4jCbOKFxefe7U="
}
},
"mode" : "15"
}
}
}
{
"TabRangePasteResult" :
{
"result" : "0"
}
}
public static TabRangePasteResult PasteTabRange(string moniker, string sheetKey, string address, TabRangeClipboardItem[] pasteData)
{
var somClient = new SomPortTypeClient(); // Proxy object for operation execution
// Operation execution parameters
var tTab = new TabRangePaste()
{
mon = moniker + "!Sheets!" + sheetKey + '!' + address,
tArg = new TabRangePasteArg()
{
mode = 15,
data = pasteData
}
};
// Paste cell range
var result = somClient.TabRangePaste(tTab);
return result;
}
See also: