humanemulator.net — справка.
Продукт, демо и покупка — на
хуманэмулятор.рф
|
Демо
|
Купить
|
API
|
Changelog
cell_add_annotation
cell_add_annotation($path,$sheet,$row,$col,$annotation_author,$annotation_comment,$json_annotation_settings=''); -Функция на вход принимает параметры:
:
Пример использования
<?php // Scenario: Add annotation to a cell in LibreOffice Calc spreadsheet $xhe_host = getenv("RPABOT_HOST_URL"); // Connect functional objects if not already connected if (!isset($path)){ $path = "../../../Templates/init.php"; require($path); } // info echo "\n<span >libreOfficeCalc->" . basename (__FILE__) . "</span>\n"; // Example 1 echo "1. Add annotation to cell B2[3, 2]: \n"; $filePath = "test/test.ods"; $sheetIndex = 0; $row = 3; $column = 2; $author = "Author"; $comment = "Comment 1"; $annotationSettings = '{"x": "2cm", "y": "4cm"}'; $res1 = SYSTEM::$libreOfficeCalc->cell_add_annotation($filePath, $sheetIndex, $row, $column, $author, $comment, $annotationSettings); $res1 = $res1 ? 'true' : 'false'; echo "Annotation added: $res1\n"; // end echo "\n"; // Quit the application WINDOW::$app->quit(); ?>
# Additional paths import sys sys.path.insert(0, '../../../Templates PY/') xhe_host = "127.0.0.1:7010" from xweb_human_emulator import * # начало echo("<hr><font color=blue>libreOfficeCalc->cell_add_annotation</font><hr>") # 1 echo("1. Установить всплывающую подсказку для ячейки B2[3, 2]: \n") annotationSettings = '{"x": "2cm", "y": "4cm"}' echo(libreOfficeCalc.cell_add_annotation("test\\test.ods", 0, 3, 2, "Author", "Comment 1", annotationSettings)) # посмотрим app.shell_execute("open","test\\test.ods") # Quit app.quit()
#region using using System; using System.Diagnostics; using System.Collections.Generic; using System.Linq; using System.IO; using System.Text; using System.Threading; using XHE; using XHE.XHE_DOM; using XHE.XHE_System; using XHE.XHE_Window; using XHE.XHE_Web; #endregion class Program : XHEScript { static void Main(string[] args) { // init XHE server = Environment.GetEnvironmentVariable("RPABOT_HOST_URL"); InitXHE(); // начало echo("<hr><font color=blue>libreOfficeCalc.cell_add_annotation</font><hr>"); // 1 echo("1. Установить всплывающую подсказку для ячейки B2[3, 2]: \n"); var annotationSettings = @"{'x': '2cm', 'y': '4cm'}"; var res1 = libreOfficeCalc.cell_add_annotation("test\\test.ods", 0, 3, 2, "Author", "Comment 1", annotationSettings); echo(res1 + "\n"); // посмотрим app.shell_execute("open", "test\\test.ods"); // Quit app.quit(); } }
xhe_host = "127.0.0.1:7010"; // подключим функциональные объекты, если еще не подключен require("../../../Templates JS/init.js"); // начало echo("<hr><font color=blue>libreOfficeCalc->cell_add_annotation</font><hr>"); // 1 echo("1. Установить всплывающую подсказку для ячейки B2[3, 2]: \n"); const annotationSettings = '{"x": "2cm", "y": "4cm"}'; const res1 = libreOfficeCalc.cell_add_annotation("test\\test.ods", 0, 3, 2, "Author", "Comment 1", annotationSettings); echo(res1 + "\n"); // посмотрим app.shell_execute("open","test\\test.ods"); // Quit app.quit();
=============================================
libreofficecalc Объекты DOM System Vision Web Window
=============================================
если что-то непонятно или необходимо узнать или считаете что надо добавить по работе этой функции, пишите в комментарии или на наш форум
.