AllLangHelp_sbasic.mk | 1 source/auxiliary/sbasic.tree | 1 source/text/sbasic/shared/03010300.xhp | 10 +-- source/text/sbasic/shared/03010301.xhp | 15 ++--- source/text/sbasic/shared/03010302.xhp | 12 ++-- source/text/sbasic/shared/03010303.xhp | 15 ++--- source/text/sbasic/shared/03010304.xhp | 10 +-- source/text/sbasic/shared/03010305.xhp | 28 ++++++--- source/text/sbasic/shared/03010306.xhp | 68 ++++++++++++++++++++++++ source/text/sbasic/shared/03103350.xhp | 4 - source/text/sbasic/shared/compatibilitymode.xhp | 5 + 11 files changed, 124 insertions(+), 45 deletions(-)
New commits: commit fb0af5ca08c6c9cff2223e641dbd73f9cd2c47c0 Author: Olivier Hallot <olivier.hal...@libreoffice.org> AuthorDate: Sun Dec 19 13:18:31 2021 -0300 Commit: Olivier Hallot <olivier.hal...@libreoffice.org> CommitDate: Mon Dec 20 13:10:45 2021 +0100 tdf#145725 VBA mode for RGB functions and warnings + Added a RGB [VBA] page specific to VBA mode for RGB stressing differences + placed warnings on Red vs Blue color interchange in VBA mode + Refactored here and there. Change-Id: I0556babb7c3a4bd3eeff1bfe6993624aa0e78d6d Reviewed-on: https://gerrit.libreoffice.org/c/help/+/127098 Tested-by: Jenkins Reviewed-by: Olivier Hallot <olivier.hal...@libreoffice.org> diff --git a/AllLangHelp_sbasic.mk b/AllLangHelp_sbasic.mk index d941abf42..b474f1396 100644 --- a/AllLangHelp_sbasic.mk +++ b/AllLangHelp_sbasic.mk @@ -123,6 +123,7 @@ $(eval $(call gb_AllLangHelp_add_helpfiles,sbasic,\ helpcontent2/source/text/sbasic/shared/03010303 \ helpcontent2/source/text/sbasic/shared/03010304 \ helpcontent2/source/text/sbasic/shared/03010305 \ + helpcontent2/source/text/sbasic/shared/03010306 \ helpcontent2/source/text/sbasic/shared/03020000 \ helpcontent2/source/text/sbasic/shared/03020100 \ helpcontent2/source/text/sbasic/shared/03020101 \ diff --git a/source/auxiliary/sbasic.tree b/source/auxiliary/sbasic.tree index e6e20b83f..2a0b27123 100644 --- a/source/auxiliary/sbasic.tree +++ b/source/auxiliary/sbasic.tree @@ -263,6 +263,7 @@ <topic id="sbasic/text/sbasic/shared/03020104.xhp">Reset Statement</topic> <topic id="sbasic/text/sbasic/shared/Resume.xhp">Resume Statement</topic> <topic id="sbasic/text/sbasic/shared/03010305.xhp">RGB Function</topic> + <topic id="sbasic/text/sbasic/shared/03010306.xhp">RGB Function [VBA]</topic> <topic id="sbasic/text/sbasic/shared/03120307.xhp">Right Function</topic> <topic id="sbasic/text/sbasic/shared/03020413.xhp">RmDir Statement</topic> <topic id="sbasic/text/sbasic/shared/03080302.xhp">Rnd Function</topic> diff --git a/source/text/sbasic/shared/03010300.xhp b/source/text/sbasic/shared/03010300.xhp index 29872415f..ee93251cd 100644 --- a/source/text/sbasic/shared/03010300.xhp +++ b/source/text/sbasic/shared/03010300.xhp @@ -1,6 +1,4 @@ <?xml version="1.0" encoding="UTF-8"?> - - <!-- * This file is part of the LibreOffice project. * @@ -18,7 +16,6 @@ * except in compliance with the License. You may obtain a copy of * the License at http://www.apache.org/licenses/LICENSE-2.0 . --> - <helpdocument version="1.0"> <meta> <topic id="textsbasicshared03010300xml" indexer="include" status="PUBLISH"> @@ -30,10 +27,10 @@ </history> </meta> <body> - - + + <section id="color"> - <paragraph id="hd_id3157896" role="heading" level="1" xml-lang="en-US"><link href="text/sbasic/shared/03010300.xhp" name="Color Functions">Color Functions</link></paragraph> + <h1 id="hd_id3157896"><link href="text/sbasic/shared/03010300.xhp" name="Color Functions">Color Functions</link></h1> <paragraph role="paragraph" id="par_id3155555" xml-lang="en-US">This section describes Runtime functions used to define colors.</paragraph> </section> <embed href="text/sbasic/shared/03010301.xhp#blue"/> @@ -41,5 +38,6 @@ <embed href="text/sbasic/shared/03010303.xhp#red"/> <embed href="text/sbasic/shared/03010304.xhp#qbcolor"/> <embed href="text/sbasic/shared/03010305.xhp#rgb"/> + <embed href="text/sbasic/shared/03010306.xhp#rgbvba"/> </body> </helpdocument> diff --git a/source/text/sbasic/shared/03010301.xhp b/source/text/sbasic/shared/03010301.xhp index a56a0e2a3..b5995ab84 100644 --- a/source/text/sbasic/shared/03010301.xhp +++ b/source/text/sbasic/shared/03010301.xhp @@ -27,32 +27,33 @@ <body> - <section id="blue"> <bookmark xml-lang="en-US" branch="index" id="bm_id3149180"> <bookmark_value>Blue function</bookmark_value> </bookmark> - -<paragraph id="hd_id3149180" role="heading" level="1" xml-lang="en-US"><link href="text/sbasic/shared/03010301.xhp" name="Blue Function">Blue Function</link></paragraph> +<h1 id="hd_id3149180"><link href="text/sbasic/shared/03010301.xhp" name="Blue Function">Blue Function</link></h1> <paragraph id="par_id3156343" role="paragraph" xml-lang="en-US">Returns the blue component of the specified composite color code.</paragraph> </section> -<paragraph id="hd_id3149670" role="heading" level="2" xml-lang="en-US">Syntax:</paragraph> +<embed href="text/sbasic/shared/00000003.xhp#functsyntax"/> <bascode> <paragraph id="par_id3149457" localize="false" role="bascode" xml-lang="en-US">Blue (Color As Long)</paragraph> </bascode> -<paragraph id="hd_id3149656" role="heading" level="2" xml-lang="en-US">Return value:</paragraph> +<embed href="text/sbasic/shared/00000003.xhp#functvalue"/> <paragraph id="par_id3154365" role="paragraph" xml-lang="en-US">Integer</paragraph> -<paragraph id="hd_id3156423" role="heading" level="2" xml-lang="en-US">Parameter:</paragraph> +<embed href="text/sbasic/shared/00000003.xhp#functparameters"/> <paragraph id="par_id3150448" role="paragraph" xml-lang="en-US"> <emph>Color value</emph>: Long integer expression that specifies any composite color code for which to return the blue component.</paragraph> +<warning id="par_id671639922129017">Under VBA compatibility mode (<link href="text/sbasic/shared/03103350.xhp" name="vbasupport"><literal>Option VBASupport 1</literal></link>), the function Blue() is incompatible with VBA colors, when color from previous call to <link href="text/sbasic/shared/03010306.xhp" name="linkrgbvba"><literal>function RGB [VBA]</literal></link> is passed. +</warning> + <embed href="text/sbasic/shared/00000003.xhp#errorcode"/> <embed href="text/sbasic/shared/00000003.xhp#err5"/> <embed href="text/sbasic/shared/03010303.xhp#ColorPickerDialog"/> -<paragraph id="hd_id3153091" role="heading" level="2" xml-lang="en-US">Example:</paragraph> +<embed href="text/sbasic/shared/00000003.xhp#functexample"/> <bascode> <paragraph id="par_idm1073171488" role="bascode" localize="false" xml-lang="en-US">Sub ExampleColor</paragraph> <paragraph id="par_idm1073170256" role="bascode" localize="false" xml-lang="en-US">Dim lVar As Long</paragraph> diff --git a/source/text/sbasic/shared/03010302.xhp b/source/text/sbasic/shared/03010302.xhp index aec9e1e10..0b175281f 100644 --- a/source/text/sbasic/shared/03010302.xhp +++ b/source/text/sbasic/shared/03010302.xhp @@ -34,25 +34,25 @@ </bookmark> -<paragraph id="hd_id3148947" role="heading" level="1" xml-lang="en-US"><link href="text/sbasic/shared/03010302.xhp" name="Green Function">Green Function</link></paragraph> +<h1 id="hd_id3148947"><link href="text/sbasic/shared/03010302.xhp" name="Green Function">Green Function</link></h1> <paragraph id="par_id3153361" role="paragraph" xml-lang="en-US">Returns the Green component of the given composite color code.</paragraph> </section> -<paragraph id="hd_id3154140" role="heading" level="2" xml-lang="en-US">Syntax:</paragraph> +<embed href="text/sbasic/shared/00000003.xhp#functsyntax"/> <bascode> <paragraph id="par_id3153969" localize="false" role="bascode" xml-lang="en-US">Green (Color As Long)</paragraph> </bascode> -<paragraph id="hd_id3154124" role="heading" level="2" xml-lang="en-US">Return value:</paragraph> +<embed href="text/sbasic/shared/00000003.xhp#functvalue"/> <paragraph id="par_id3153194" role="paragraph" xml-lang="en-US">Integer</paragraph> -<paragraph id="hd_id3154909" role="heading" level="2" xml-lang="en-US">Parameter:</paragraph> +<embed href="text/sbasic/shared/00000003.xhp#functparameters"/> <paragraph id="par_id3153770" role="paragraph" xml-lang="en-US"> <emph>Color</emph>: Long integer expression that specifies a composite color code for which to return the Green component.</paragraph> <embed href="text/sbasic/shared/00000003.xhp#errorcode"/> <embed href="text/sbasic/shared/00000003.xhp#err5"/> <embed href="text/sbasic/shared/03010303.xhp#ColorPickerDialog"/> -<paragraph id="hd_id3149664" role="heading" level="2" xml-lang="en-US">Example:</paragraph> +<embed href="text/sbasic/shared/00000003.xhp#functexample"/> <bascode> <paragraph id="par_idm1341170976" role="bascode" localize="false" xml-lang="en-US">Sub ExampleColor</paragraph> <paragraph id="par_idm1341169744" role="bascode" localize="false" xml-lang="en-US">Dim lVar As Long</paragraph> @@ -65,4 +65,4 @@ </bascode> </body> -</helpdocument> \ No newline at end of file +</helpdocument> diff --git a/source/text/sbasic/shared/03010303.xhp b/source/text/sbasic/shared/03010303.xhp index d7ac7717a..ddd2b8588 100644 --- a/source/text/sbasic/shared/03010303.xhp +++ b/source/text/sbasic/shared/03010303.xhp @@ -27,27 +27,28 @@ <body> - <section id="red"> <bookmark xml-lang="en-US" branch="index" id="bm_id3148947"> <bookmark_value>Red function</bookmark_value> </bookmark> -<paragraph id="hd_id3148947" role="heading" level="1" xml-lang="en-US"><link href="text/sbasic/shared/03010303.xhp" name="Red Function">Red Function</link></paragraph> +<h1 id="hd_id3148947"><link href="text/sbasic/shared/03010303.xhp" name="Red Function">Red Function</link></h1> <paragraph id="par_id3149656" role="paragraph" xml-lang="en-US">Returns the Red component of the specified composite color code.</paragraph> </section> -<paragraph id="hd_id3148799" role="heading" level="2" xml-lang="en-US">Syntax:</paragraph> +<embed href="text/sbasic/shared/00000003.xhp#functsyntax"/> <bascode> <paragraph id="par_id3150448" localize="false" role="bascode" xml-lang="en-US">Red (ColorNumber As Long)</paragraph> </bascode> -<paragraph id="hd_id3151042" role="heading" level="2" xml-lang="en-US">Return value:</paragraph> +<embed href="text/sbasic/shared/00000003.xhp#functvalue"/> <paragraph id="par_id3145173" role="paragraph" xml-lang="en-US">Integer</paragraph> -<paragraph id="hd_id3154685" role="heading" level="2" xml-lang="en-US">Parameter:</paragraph> +<embed href="text/sbasic/shared/00000003.xhp#functparameters"/> <paragraph id="par_id3150440" role="paragraph" xml-lang="en-US"> <emph>ColorNumber</emph>: Long integer expression that specifies any composite color code for which to return the Red component.</paragraph> +<warning id="par_id671639922129017">Under VBA compatibility mode (<link href="text/sbasic/shared/03103350.xhp" name="vbasupport"><literal>Option VBASupport 1</literal></link>), the function Red() is incompatible with VBA colors, when color from previous call to <link href="text/sbasic/shared/03010306.xhp" name="linkrgbvba"><literal>function RGB [VBA]</literal></link> is passed. +</warning> <embed href="text/sbasic/shared/00000003.xhp#errorcode"/> <embed href="text/sbasic/shared/00000003.xhp#err5"/> @@ -55,7 +56,7 @@ <tip id="par_id961588421825749">The <link href="text/shared/optionen/01010501.xhp" name="color picker dialog">color picker dialog</link> details the red, green and blue components of a composite color code, as well as its hexadecimal expression. <link href="text/shared/guide/text_color.xhp" name="Changing the color of text">Changing the color of text</link> and selecting <emph>Custom color</emph> displays the color picker dialog.</tip> </section> -<paragraph id="hd_id3148575" role="heading" level="2" xml-lang="en-US">Example:</paragraph> +<embed href="text/sbasic/shared/00000003.xhp#functexample"/> <bascode> <paragraph id="par_idm1341092848" role="bascode" localize="false" xml-lang="en-US">Sub ExampleColor</paragraph> <paragraph id="par_idm1341091616" role="bascode" localize="false" xml-lang="en-US">Dim lVar As Long</paragraph> @@ -68,4 +69,4 @@ </bascode> </body> -</helpdocument> \ No newline at end of file +</helpdocument> diff --git a/source/text/sbasic/shared/03010304.xhp b/source/text/sbasic/shared/03010304.xhp index 0a0b46b85..2be24252d 100644 --- a/source/text/sbasic/shared/03010304.xhp +++ b/source/text/sbasic/shared/03010304.xhp @@ -32,17 +32,17 @@ <bookmark_value>QBColor function</bookmark_value> </bookmark> -<paragraph id="hd_id3149670" role="heading" level="1" xml-lang="en-US"><link href="text/sbasic/shared/03010304.xhp" name="QBColor Function">QBColor Function</link></paragraph> +<h1 id="hd_id3149670"><link href="text/sbasic/shared/03010304.xhp" name="QBColor Function">QBColor Function</link></h1> <paragraph id="par_id3150359" role="paragraph" xml-lang="en-US">Returns the <link href="text/sbasic/shared/03010305.xhp" name="RGB">RGB</link> color code of the color passed as a color value through an older MS-DOS based programming system.</paragraph> </section> -<paragraph id="hd_id3154140" role="heading" level="2" xml-lang="en-US">Syntax:</paragraph> +<embed href="text/sbasic/shared/00000003.xhp#functsyntax"/> <paragraph id="par_id3151042" localize="false" role="code" xml-lang="en-US">QBColor (ColorNumber As Integer)</paragraph> -<paragraph id="hd_id3145172" role="heading" level="2" xml-lang="en-US">Return value:</paragraph> +<embed href="text/sbasic/shared/00000003.xhp#functvalue"/> <paragraph id="par_id3154685" localize="false" role="paragraph" xml-lang="en-US">Long</paragraph> -<paragraph id="hd_id3156560" role="heading" level="2" xml-lang="en-US">Parameter:</paragraph> +<embed href="text/sbasic/shared/00000003.xhp#functparameters"/> <paragraph id="par_id3161832" role="paragraph" xml-lang="en-US"> <emph>ColorNumber</emph>: Any integer expression that specifies the color value of the color passed from an older MS-DOS based programming system.</paragraph> <paragraph id="par_id3147318" role="paragraph" xml-lang="en-US"> <emph>ColorNumber</emph> can be assigned the following values:</paragraph> <paragraph id="par_id3152576" role="paragraph" xml-lang="en-US">0 : Black</paragraph> @@ -65,7 +65,7 @@ <embed href="text/sbasic/shared/00000003.xhp#errorcode"/> <embed href="text/sbasic/shared/00000003.xhp#err5"/> -<paragraph id="hd_id3148406" role="heading" level="2" xml-lang="en-US">Example:</paragraph> +<embed href="text/sbasic/shared/00000003.xhp#functexample"/> <bascode> <paragraph id="par_idm1341247424" role="bascode" localize="false" xml-lang="en-US">Sub ExampleQBColor</paragraph> <paragraph id="par_idm1341246192" role="bascode" localize="false" xml-lang="en-US">Dim iColor As Integer</paragraph> diff --git a/source/text/sbasic/shared/03010305.xhp b/source/text/sbasic/shared/03010305.xhp index 3b95b396f..c7d3deb76 100644 --- a/source/text/sbasic/shared/03010305.xhp +++ b/source/text/sbasic/shared/03010305.xhp @@ -26,37 +26,46 @@ </meta> <body> - - <section id="rgb"> <bookmark xml-lang="en-US" branch="index" id="bm_id851576768070903"> <bookmark_value>RGB function</bookmark_value> </bookmark> -<paragraph id="hd_id3150792" role="heading" level="1" xml-lang="en-US"><link href="text/sbasic/shared/03010305.xhp" name="RGB Function">RGB Function</link></paragraph> +<h1 id="hd_id3150792"><link href="text/sbasic/shared/03010305.xhp" name="RGB Function">RGB Function</link></h1> <paragraph id="par_id3150447" role="paragraph" xml-lang="en-US">Returns a <literal>Long</literal> integer color value consisting of red, green, and blue components.</paragraph> </section> -<paragraph id="hd_id3147229" role="heading" level="2" xml-lang="en-US">Syntax:</paragraph> +<embed href="text/sbasic/shared/00000003.xhp#functsyntax"/> <bascode> <paragraph id="par_id3155132" localize="false" role="bascode" xml-lang="en-US">RGB (Red, Green, Blue)</paragraph> </bascode> -<paragraph id="hd_id3156442" role="heading" level="2" xml-lang="en-US">Return value:</paragraph> +<embed href="text/sbasic/shared/00000003.xhp#functvalue"/> <paragraph id="par_id3159153" localize="false" role="paragraph" xml-lang="en-US">Long</paragraph> -<paragraph id="hd_id3154013" role="heading" level="2" xml-lang="en-US">Parameter:</paragraph> +<embed href="text/sbasic/shared/00000003.xhp#functparameters"/> <section id="parameters"> +<section id="parameters1"> <paragraph id="par_id3152597" role="paragraph" xml-lang="en-US"> <emph>red</emph>: Any integer expression that represents the red component (0-255) of the composite color.</paragraph> <paragraph id="par_id3146974" role="paragraph" xml-lang="en-US"> <emph>green</emph>: Any integer expression that represents the green component (0-255) of the composite color.</paragraph> <paragraph id="par_id3151113" role="paragraph" xml-lang="en-US"> <emph>blue</emph>: Any integer expression that represents the blue component (0-255) of the composite color.</paragraph> +</section> +<paragraph role="paragraph" id="par_id101639922410794">The resulting <literal>Long</literal> value is calculated with the following formula:<br/> +<literal>Result = red×65536 + green×256 + blue</literal>. +</paragraph> +<warning id="par_id671639922129017">Under VBA compatibility mode (<link href="text/sbasic/shared/03103350.xhp" name="vbasupport"><literal>Option VBASupport 1</literal></link>), the <literal>Long</literal> value is calculated as +<br/> +<literal>Result = red + green×256 + blue×65536</literal><br/> +See <link href="text/sbasic/shared/03010306.xhp" name="rgbvba">RGB Function [VBA]</link> +</warning> + <tip id="par_id211587653651037">The <link href="text/shared/optionen/01010501.xhp" name="color picker dialog">color picker dialog</link> helps computing red, green and blue components of a composite color. <link href="text/shared/guide/text_color.xhp" name="Changing the color of text">Changing the color of text</link> and selecting <emph>Custom color</emph> displays the color picker dialog.</tip> </section> <embed href="text/sbasic/shared/00000003.xhp#errorcode"/> <embed href="text/sbasic/shared/00000003.xhp#err5"/> -<paragraph id="hd_id3147435" role="heading" level="2" xml-lang="en-US">Example:</paragraph> +<embed href="text/sbasic/shared/00000003.xhp#functexample"/> <bascode> <paragraph id="par_idm1340938032" role="bascode" localize="false" xml-lang="en-US">Sub ExampleColor</paragraph> <paragraph id="par_idm1340936800" role="bascode" localize="false" xml-lang="en-US">Dim lVar As Long</paragraph> @@ -67,7 +76,6 @@ <paragraph id="par_id3150716" role="bascode" xml-lang="en-US"> "blue= " & blue(lVar) & Chr(13) , 64,"colors"</paragraph> <paragraph id="par_idm1340927072" role="bascode" localize="false" xml-lang="en-US">End Sub</paragraph> </bascode> - -</body> -</helpdocument> \ No newline at end of file +</body> +</helpdocument> diff --git a/source/text/sbasic/shared/03010306.xhp b/source/text/sbasic/shared/03010306.xhp new file mode 100644 index 000000000..9dacef585 --- /dev/null +++ b/source/text/sbasic/shared/03010306.xhp @@ -0,0 +1,68 @@ +<?xml version="1.0" encoding="UTF-8"?> +<helpdocument version="1.0"> +<!-- + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . +--> + +<meta> + <topic id="textsbasicshared03010305xml" indexer="include" status="PUBLISH"> + <title id="tit" xml-lang="en-US">RGB Function [VBA]</title> + <filename>/text/sbasic/shared/03010306.xhp</filename> + </topic> +</meta> + +<body> + +<section id="rgbvba"> +<bookmark xml-lang="en-US" branch="index" id="bm_id851576768070903"> + <bookmark_value>RGB function [VBA]</bookmark_value> +</bookmark> + +<h1 id="hd_id3150792"><link href="text/sbasic/shared/03010305.xhp" name="RGB Function">RGB Function [VBA]</link></h1> +<paragraph id="par_id3150447" role="paragraph" xml-lang="en-US">Returns a <literal>Long</literal> integer color value consisting of red, green, and blue components, according to VBA color formula.</paragraph> +</section> +<embed href="text/sbasic/shared/00000003.xhp#vbasupport"/> +<embed href="text/sbasic/shared/00000003.xhp#functsyntax"/> +<bascode> +<paragraph id="par_id3155132" localize="false" role="bascode" xml-lang="en-US">RGB (Red, Green, Blue)</paragraph> +</bascode> + +<embed href="text/sbasic/shared/00000003.xhp#functvalue"/> +<paragraph id="par_id3159153" localize="false" role="paragraph" xml-lang="en-US">Long</paragraph> + +<embed href="text/sbasic/shared/00000003.xhp#functparameters"/> +<embed href="text/sbasic/shared/03010305.xhp#parameters1"/> +<warning id="par_id671639922129017">Because of the VBA compatibility mode (<link href="text/sbasic/shared/03103350.xhp" name="vbasupport"><literal>Option VBASupport 1</literal></link>), the <literal>Long</literal> value is calculated as<br/> +<literal>Result = red + green×256 + blue×65536</literal>. +</warning> + +<embed href="text/sbasic/shared/00000003.xhp#errorcode"/> +<embed href="text/sbasic/shared/00000003.xhp#err5"/> + +<embed href="text/sbasic/shared/00000003.xhp#functexample"/> +<bascode> +<paragraph role="bascode" id="par_id551639925302816" xml-lang="en-US" localize="false">Option VBASupport 1</paragraph> +<paragraph id="par_idm1340938032" role="bascode" localize="false" xml-lang="en-US">Sub ExampleRGBVBA</paragraph> +<paragraph id="par_idm1340936800" role="bascode" localize="false" xml-lang="en-US">Dim lVar As Long</paragraph> +<paragraph id="par_idm1340935568" role="bascode" localize="false" xml-lang="en-US"> lVar = rgb(128,0,200)</paragraph> +<paragraph role="bascode" id="par_id621639924528952" xml-lang="en-US" > Print lVar; ' returns 13107328</paragraph> +<paragraph id="par_idm1340927072" role="bascode" localize="false" xml-lang="en-US">End Sub</paragraph> +</bascode> + +</body> + +</helpdocument> diff --git a/source/text/sbasic/shared/03103350.xhp b/source/text/sbasic/shared/03103350.xhp index 687b1ffb9..1a0b9c522 100644 --- a/source/text/sbasic/shared/03103350.xhp +++ b/source/text/sbasic/shared/03103350.xhp @@ -26,8 +26,6 @@ </meta> <body> - - <section id="optionVBASupport"> <bookmark xml-lang="en-US" branch="index" id="bm_id3145090"> <bookmark_value>Microsoft Excel macros support;Enable</bookmark_value> @@ -38,8 +36,8 @@ <h1 id="hd_id3145090"><variable id="vbasupportstatement"><link href="text/sbasic/shared/03103350.xhp" name="Option VBASupport Statement">Option VBASupport Statement</link></variable></h1> <paragraph id="par_id3148538" role="paragraph" xml-lang="en-US">Specifies that %PRODUCTNAME Basic will support some VBA statements, functions and objects.</paragraph> </section> -<paragraph id="par_id051720171055367194" role="note" xml-lang="en-US">The support for VBA is not complete, but covers a large portion of the common usage patterns.</paragraph> <embed href="text/sbasic/shared/00000003.xhp#beforeexecutable"/> +<note id="par_id051720171055367194">The support for VBA is not complete, but covers a large portion of the common usage patterns.</note> <warning id="par_id941552915528262">When VBA support is enabled, %PRODUCTNAME Basic function arguments and return values are the same as their VBA functions counterparts. When the support is disabled, %PRODUCTNAME Basic functions may accept arguments and return values different of their VBA counterparts.</warning> <embed href="text/sbasic/shared/00000003.xhp#functsyntax"/> <paragraph id="par_id3149514" role="code" localize="false" xml-lang="en-US">Option VBASupport {1|0}</paragraph> diff --git a/source/text/sbasic/shared/compatibilitymode.xhp b/source/text/sbasic/shared/compatibilitymode.xhp index ef2ac443b..a7e0e1a33 100644 --- a/source/text/sbasic/shared/compatibilitymode.xhp +++ b/source/text/sbasic/shared/compatibilitymode.xhp @@ -21,7 +21,7 @@ </bookmark> <section id="compatibilitymodefunction"> <h1 id="N0118"><variable id="compatibilitymodeh1"><link href="text/sbasic/shared/compatibilitymode.xhp" name="CompatibilityMode">CompatibilityMode() Function</link></variable></h1> - <paragraph role="paragraph" id="N0120"><literal>CompatibilityMode()</literal> function is controlling runtime mode and affects all code executed after setting or resetting the mode. </paragraph> + <paragraph role="paragraph" id="N0120"><literal>CompatibilityMode()</literal> function controls runtime mode and affects all code executed after setting or resetting the mode. </paragraph> </section> <warning id="N0119">Use this feature with caution, limit it to document conversion for example.</warning> <note id="par_id271561645872679"><literal>Option Compatible</literal> turns on VBA compatibility at module level for the %PRODUCTNAME Basic interpreter.</note> @@ -30,6 +30,9 @@ <listitem><paragraph role="listitem" id="N0122">Creating enumerations with <link href="text/sbasic/shared/enum.xhp" name="enum statement">Enum statement</link></paragraph></listitem> <listitem><paragraph role="listitem" id="N0124">Running <literal>RmDir</literal> command in VBA mode. In VBA only empty directories are removed by <literal>RmDir</literal> while %PRODUCTNAME Basic removes a directory recursively.</paragraph></listitem> <listitem><paragraph role="listitem" id="N0125">Changing behavior of Basic <literal>Dir</literal> command. The directory flag (16) for the <literal>Dir</literal> command means that only directories are returned in %PRODUCTNAME Basic, while in VBA normal files and directories are returned.</paragraph></listitem> + <listitem> + <paragraph id="par_id901639929393688" role="listitem">Color components calculation with the <link href="text/sbasic/shared/03010303.xhp" name="linkred"><literal>Red</literal></link> and <link href="text/sbasic/shared/03010301.xhp" name="linkblue"><literal>Blue</literal></link> functions which <emph>are interchanged</emph> (The <link href="text/sbasic/shared/03010302.xhp" name="linkgreen"><literal>Green</literal></link> function is not affected).</paragraph> + </listitem> </list> <note id="N0126"><literal>CompatibilityMode()</literal> function may be necessary when resorting to <literal>Option Compatible</literal> or <literal>Option VBASupport</literal> compiler modes.</note> <embed href="text/sbasic/shared/00000003.xhp#functsyntax"/>