<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How to lock the values of an array parameter ? in Libraries &amp; objects</title>
    <link>https://community.graphisoft.com/t5/Libraries-objects/How-to-lock-the-values-of-an-array-parameter/m-p/284979#M2717</link>
    <description>You cannot lock part of array or apply specific range of variables for part of array - only to whole array.&lt;BR /&gt;
&lt;BR /&gt;
To solve this problem I wrote a script, where first I'm creating temporary array&lt;BR /&gt;
&lt;BR /&gt;

&lt;PRE&gt;DIM TempArray[]&lt;/PRE&gt;

&lt;BR /&gt;
then using FOR - NEXT program goes through each array value, checking specific condition and if it's okey - copy it's value to temporary array. &lt;BR /&gt;
&lt;BR /&gt;

&lt;PRE&gt;TempArray[ i ] = MyArray[ i ]&lt;/PRE&gt;

&lt;BR /&gt;
If the condition is false, let say one editable hotspot exceed it's range, let say A&amp;gt;1.00 - program writes into array that A=1.00&lt;BR /&gt;
&lt;BR /&gt;

&lt;PRE&gt;IF MyArray[ i ]&amp;gt;1 THEN TempArray[ i ]=1&lt;/PRE&gt;

&lt;BR /&gt;
After loop went though all array, I use &lt;BR /&gt;
&lt;BR /&gt;

&lt;PRE&gt;MyArray = TempArray
PARAMETERS MyArray = MyArray&lt;/PRE&gt;</description>
    <pubDate>Mon, 24 May 2021 18:37:29 GMT</pubDate>
    <dc:creator>Podolsky</dc:creator>
    <dc:date>2021-05-24T18:37:29Z</dc:date>
    <item>
      <title>How to lock the values of an array parameter ?</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/How-to-lock-the-values-of-an-array-parameter/m-p/284978#M2716</link>
      <description>&lt;DIV class="actalk-migrated-content"&gt;&lt;R&gt;Hi there,&lt;BR /&gt;
&lt;BR /&gt;
I have a number of array parameters that are used for graphical editing hotspots, and I need to know how to block the values in the array parameter so that it doesn't change if a certain circumstance is met ?&lt;BR /&gt;
&lt;BR /&gt;
I have already been able to make it with normal parameters as shown in this &lt;A href="https://archicad-talk.graphisoft.com/viewtopic.php?f=6&amp;amp;t=66199" target="_blank"&gt;thread&lt;/A&gt;.&lt;/R&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 14 Feb 2019 21:52:28 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/How-to-lock-the-values-of-an-array-parameter/m-p/284978#M2716</guid>
      <dc:creator>Nader Belal</dc:creator>
      <dc:date>2019-02-14T21:52:28Z</dc:date>
    </item>
    <item>
      <title>Re: How to lock the values of an array parameter ?</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/How-to-lock-the-values-of-an-array-parameter/m-p/284979#M2717</link>
      <description>You cannot lock part of array or apply specific range of variables for part of array - only to whole array.&lt;BR /&gt;
&lt;BR /&gt;
To solve this problem I wrote a script, where first I'm creating temporary array&lt;BR /&gt;
&lt;BR /&gt;

&lt;PRE&gt;DIM TempArray[]&lt;/PRE&gt;

&lt;BR /&gt;
then using FOR - NEXT program goes through each array value, checking specific condition and if it's okey - copy it's value to temporary array. &lt;BR /&gt;
&lt;BR /&gt;

&lt;PRE&gt;TempArray[ i ] = MyArray[ i ]&lt;/PRE&gt;

&lt;BR /&gt;
If the condition is false, let say one editable hotspot exceed it's range, let say A&amp;gt;1.00 - program writes into array that A=1.00&lt;BR /&gt;
&lt;BR /&gt;

&lt;PRE&gt;IF MyArray[ i ]&amp;gt;1 THEN TempArray[ i ]=1&lt;/PRE&gt;

&lt;BR /&gt;
After loop went though all array, I use &lt;BR /&gt;
&lt;BR /&gt;

&lt;PRE&gt;MyArray = TempArray
PARAMETERS MyArray = MyArray&lt;/PRE&gt;</description>
      <pubDate>Mon, 24 May 2021 18:37:29 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/How-to-lock-the-values-of-an-array-parameter/m-p/284979#M2717</guid>
      <dc:creator>Podolsky</dc:creator>
      <dc:date>2021-05-24T18:37:29Z</dc:date>
    </item>
  </channel>
</rss>

