SetChartHint

Syntax

bool SetChartHint(ChartHintId tHint, ChartHint tArg)

Parameters

tHint. Moniker for working with chart tooltips.

tArg. Tooltip settings that should be applied.

Description

The SetChartHint operation changes chart tooltip settings.

Comments

To execute the operation, in the tHint field specify moniker for working with chart tooltips, and in the tArg field specify the settings to be applied. The moniker can be created based on the chart moniker specified in the GetChart, SetChart, GetChartSeries operations. The moniker is created in the following format: 'Chart moniker'!Hint'.

The operation results in the logical True if the settings were applied successfully.

Example

Below is the example of changing chart tooltip settings. The request contains moniker for working with tooltips and settings to be applied. The response contains whether changes were applied successfully.

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">
<SetChartHint xmlns="http://www.fsight.ru/PP.SOM.Som">
<tHint xmlns="">
  <id>EDKKJPHJEHILFOAEPIMEEFNEPLBBPMIENIOCOOKNODOIOCGE!M!S!PPDJOMGIJEHILFOAEKDIEBFPLEKLKDGJEDJIIBCHBAEAKDPIA!Sheets!1!Objects!PrxChart1!Hint</id>
  </tHint>
<tArg xmlns="">
  <tf>%XValue</tf>
  <a>Center</a>
  <ic>true</ic>
<p>
  <clr>#000000</clr>
  <s>0</s>
  <enabled>true</enabled>
  </p>
  </tArg>
  </SetChartHint>
  </s:Body>
  </s:Envelope>

SOAP response:

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

JSON request:

{
"SetChartHint" :
{
"tHint" :
{
"id" : "EDKKJPHJEHILFOAEPIMEEFNEPLBBPMIENIOCOOKNODOIOCGE!M!S!PPDJOMGIJEHILFOAEKDIEBFPLEKLKDGJEDJIIBCHBAEAKDPIA!Sheets!1!Objects!PrxChart1!Hint"
},
"tArg" :
{
"tf" : "%XValue",
"a" : "Center",
"ic" : "true",
"p" :
{
"clr" : "#000000",
"s" : "0",
"enabled" : "true"
}
}
}
}

JSON response:

{
"SetChartHintResult" : "1"
}
public static bool SetChartHint(string chartMoniker)
{
var somClient = new SomPortTypeClient(); // Proxy object for operation execution
// Operation execution parameters
var tSet = new SetChartHint()
{
tHint = new ChartHintId() { id = chartMoniker + "!Hint" },
tArg = new ChartHint()
{
tf = "%XValue",
a = ChartHorizontalAlignment.Center,
ic = true,
p = new ChartLine()
{
enabled = true,
s = 0,
clr = "#000000" //Black
}
}
};
// Change chart tooltip settings
var result = somClient.SetChartHint(tSet);
return result;
}

See also:

Chart