bool SetUpdateSettings(string mon, ViewerUpdateSettings tArg)
mon. Moniker.
tArg. Operation execution parameters.
The SetUpdateSettings operation changes parameters of regular report automatic update.
To execute the operation, in the mon field specify moniker of regular report instance with the !Options!UpdateSettings postfix. In the tArg field set automatic update parameters to be changed. The moniker can be obtained on executing the OpenPrxMeta operation.
The operation results in the logical true, if parameters are changed successfully.
See below the example of changing regular report automatic update parameters. The request sends moniker to work with automatic update parameters and new parameters values. The response indicates whether changes are applied successfully.
{
"SetUpdateSettings" :
{
"mon" : "S1!M!S!P1!Options!UpdateSettings",
"tArg" :
{
"updateByIntervalEnabled" : "true",
"autoUpdateByData" : "true",
"AutoUpdateInterval" : "5",
"autoUpdateIntervalUnits" : "Seconds"
}
}
}
{
"SetUpdateSettingsResult" : "1"
}
public static bool SetUpdateSettings(string moniker)
{
var somClient = new SomPortTypeClient(); //Proxy object for operation execution
//Operation execution parameters
var tSet = new SetUpdateSettings()
{
tArg = new ViewerUpdateSettings()
{
updateByIntervalEnabled = true,
autoUpdateByData = true,
AutoUpdateInterval = 5,
autoUpdateIntervalUnits = TimeUnits.Seconds
},
mon = moniker + "!Options!UpdateSettings"
};
//Change parameters of regular report automatic update
var result = somClient.SetUpdateSettings(tSet);
return result;
}
See also: