<?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 Problem: Persistent Parameter Arrays Values &amp;amp; deletion in GDL</title>
    <link>https://community.graphisoft.com/t5/GDL/Problem-Persistent-Parameter-Arrays-Values-amp-deletion/m-p/277319#M4879</link>
    <description>&lt;DIV class="actalk-migrated-content"&gt;&lt;FONT color="#000000"&gt;Hi everyone,&lt;BR /&gt;&lt;BR /&gt;I have a problem with parameter arrays and deletion process that can be resumed as, inability to delete their values with every known process ...&lt;BR /&gt;&lt;BR /&gt;&lt;U&gt;&lt;/U&gt;&lt;S&gt;&lt;U&gt;&lt;U&gt;&lt;/U&gt;&lt;/U&gt;&lt;/S&gt;Background:&lt;BR /&gt;I have a bunch of 2D parameter arrays of different types mainly integers that goes in parallel (&lt;I&gt;&lt;/I&gt;&lt;S&gt;&lt;I&gt;&lt;I&gt;&lt;/I&gt;&lt;/I&gt;&lt;/S&gt;ie: all have same length and width) &lt;FONT color="#0000FF"&gt;to act as information placeholders&lt;/FONT&gt;; and the majority of these integer arrays were used with &lt;STRONG&gt;values{2}&lt;/STRONG&gt; function, and connected to the GUI using &lt;STRONG&gt;UI_INFIELD&lt;/STRONG&gt; function (&lt;I&gt;&lt;/I&gt;&lt;S&gt;&lt;I&gt;&lt;I&gt;&lt;/I&gt;&lt;/I&gt;&lt;/S&gt;or any of its version).&lt;BR /&gt;Mentioned arrays will have a size 20*50 (&lt;I&gt;&lt;/I&gt;&lt;S&gt;&lt;I&gt;&lt;I&gt;&lt;/I&gt;&lt;/I&gt;&lt;/S&gt;but I was working with a smaller version of them).&lt;BR /&gt;&lt;BR /&gt;&lt;U&gt;&lt;/U&gt;&lt;S&gt;&lt;U&gt;&lt;U&gt;&lt;/U&gt;&lt;/U&gt;&lt;/S&gt;Problem:&lt;BR /&gt;What ever process I try to delete those arrays, I find that they still have the same width, or some get deleted others as if nothing happened.&lt;BR /&gt;&lt;BR /&gt;&lt;U&gt;&lt;/U&gt;&lt;S&gt;&lt;U&gt;&lt;U&gt;&lt;/U&gt;&lt;/U&gt;&lt;/S&gt;Tested methods:&lt;/FONT&gt;
&lt;UL&gt;
&lt;LI&gt;&amp;nbsp;&lt;/LI&gt;
&lt;LI&gt;Substitution of "&lt;STRONG&gt;APPLICATION_QUERY&lt;/STRONG&gt;" function method "&lt;STRONG&gt;firstoccasion_in_progress&lt;/STRONG&gt;" with time stamp as explained in &lt;A href="https://Archicad-talk.Graphisoft.com/viewtopic.php?p=293692#p293692" target="_blank" rel="noopener"&gt;DELETE AN ITEM FROM A PARAMETER ARRAY&lt;/A&gt;&lt;/LI&gt;
&lt;LI&gt;&amp;nbsp;&lt;/LI&gt;
&lt;LI&gt;Using &lt;STRONG&gt;Parameter Buffer Manipulation&lt;/STRONG&gt; using &lt;A href="https://Archicad-talk.Graphisoft.com/memberlist.php?mode=viewprofile&amp;amp;u=5054" target="_blank" rel="noopener"&gt;Braza's&lt;/A&gt; method in &lt;A href="https://Archicad-talk.Graphisoft.com/viewtopic.php?p=162931#p162931" target="_blank" rel="noopener"&gt;LIMITING RANGE OF PARAMETER ARRAYS&lt;/A&gt; either by not copying undesired values from Parameter Arrays or Temporary Variable Arrays, of vise versa&lt;/LI&gt;
&lt;LI&gt;&amp;nbsp;&lt;/LI&gt;
&lt;LI&gt;Deleting all values from Parameter Arrays (&lt;I&gt;&lt;/I&gt;&lt;S&gt;&lt;I&gt;&lt;I&gt;&lt;/I&gt;&lt;/I&gt;&lt;/S&gt;including re-initialising them with 1-2 values) then copying the values from Temporary Variable Arrays to Parameter Arrays.&lt;BR /&gt;&lt;FONT color="#800000"&gt;In this time, many arrays didn't accept any values.&lt;/FONT&gt;&lt;/LI&gt;
&lt;LI&gt;&amp;nbsp;&lt;/LI&gt;
&lt;LI&gt;Changing parameter arrays names.&lt;/LI&gt;
&lt;LI&gt;&amp;nbsp;&lt;/LI&gt;
&lt;LI&gt;Arrays' script manipulations were defined in "&lt;STRONG&gt;Parameter Script&lt;/STRONG&gt;" &amp;amp; "&lt;STRONG&gt;Master Script&lt;/STRONG&gt;"&lt;/LI&gt;
&lt;/UL&gt;
&lt;S&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;U&gt;&lt;/U&gt;&lt;S&gt;&lt;U&gt;&lt;U&gt;&lt;/U&gt;&lt;/U&gt;&lt;/S&gt;Request:&lt;BR /&gt;A sure fire method for parameter array value update.&lt;/S&gt;&lt;/DIV&gt;</description>
    <pubDate>Mon, 26 Sep 2022 20:44:28 GMT</pubDate>
    <dc:creator>Nader Belal</dc:creator>
    <dc:date>2022-09-26T20:44:28Z</dc:date>
    <item>
      <title>Problem: Persistent Parameter Arrays Values &amp; deletion</title>
      <link>https://community.graphisoft.com/t5/GDL/Problem-Persistent-Parameter-Arrays-Values-amp-deletion/m-p/277319#M4879</link>
      <description>&lt;DIV class="actalk-migrated-content"&gt;&lt;FONT color="#000000"&gt;Hi everyone,&lt;BR /&gt;&lt;BR /&gt;I have a problem with parameter arrays and deletion process that can be resumed as, inability to delete their values with every known process ...&lt;BR /&gt;&lt;BR /&gt;&lt;U&gt;&lt;/U&gt;&lt;S&gt;&lt;U&gt;&lt;U&gt;&lt;/U&gt;&lt;/U&gt;&lt;/S&gt;Background:&lt;BR /&gt;I have a bunch of 2D parameter arrays of different types mainly integers that goes in parallel (&lt;I&gt;&lt;/I&gt;&lt;S&gt;&lt;I&gt;&lt;I&gt;&lt;/I&gt;&lt;/I&gt;&lt;/S&gt;ie: all have same length and width) &lt;FONT color="#0000FF"&gt;to act as information placeholders&lt;/FONT&gt;; and the majority of these integer arrays were used with &lt;STRONG&gt;values{2}&lt;/STRONG&gt; function, and connected to the GUI using &lt;STRONG&gt;UI_INFIELD&lt;/STRONG&gt; function (&lt;I&gt;&lt;/I&gt;&lt;S&gt;&lt;I&gt;&lt;I&gt;&lt;/I&gt;&lt;/I&gt;&lt;/S&gt;or any of its version).&lt;BR /&gt;Mentioned arrays will have a size 20*50 (&lt;I&gt;&lt;/I&gt;&lt;S&gt;&lt;I&gt;&lt;I&gt;&lt;/I&gt;&lt;/I&gt;&lt;/S&gt;but I was working with a smaller version of them).&lt;BR /&gt;&lt;BR /&gt;&lt;U&gt;&lt;/U&gt;&lt;S&gt;&lt;U&gt;&lt;U&gt;&lt;/U&gt;&lt;/U&gt;&lt;/S&gt;Problem:&lt;BR /&gt;What ever process I try to delete those arrays, I find that they still have the same width, or some get deleted others as if nothing happened.&lt;BR /&gt;&lt;BR /&gt;&lt;U&gt;&lt;/U&gt;&lt;S&gt;&lt;U&gt;&lt;U&gt;&lt;/U&gt;&lt;/U&gt;&lt;/S&gt;Tested methods:&lt;/FONT&gt;
&lt;UL&gt;
&lt;LI&gt;&amp;nbsp;&lt;/LI&gt;
&lt;LI&gt;Substitution of "&lt;STRONG&gt;APPLICATION_QUERY&lt;/STRONG&gt;" function method "&lt;STRONG&gt;firstoccasion_in_progress&lt;/STRONG&gt;" with time stamp as explained in &lt;A href="https://Archicad-talk.Graphisoft.com/viewtopic.php?p=293692#p293692" target="_blank" rel="noopener"&gt;DELETE AN ITEM FROM A PARAMETER ARRAY&lt;/A&gt;&lt;/LI&gt;
&lt;LI&gt;&amp;nbsp;&lt;/LI&gt;
&lt;LI&gt;Using &lt;STRONG&gt;Parameter Buffer Manipulation&lt;/STRONG&gt; using &lt;A href="https://Archicad-talk.Graphisoft.com/memberlist.php?mode=viewprofile&amp;amp;u=5054" target="_blank" rel="noopener"&gt;Braza's&lt;/A&gt; method in &lt;A href="https://Archicad-talk.Graphisoft.com/viewtopic.php?p=162931#p162931" target="_blank" rel="noopener"&gt;LIMITING RANGE OF PARAMETER ARRAYS&lt;/A&gt; either by not copying undesired values from Parameter Arrays or Temporary Variable Arrays, of vise versa&lt;/LI&gt;
&lt;LI&gt;&amp;nbsp;&lt;/LI&gt;
&lt;LI&gt;Deleting all values from Parameter Arrays (&lt;I&gt;&lt;/I&gt;&lt;S&gt;&lt;I&gt;&lt;I&gt;&lt;/I&gt;&lt;/I&gt;&lt;/S&gt;including re-initialising them with 1-2 values) then copying the values from Temporary Variable Arrays to Parameter Arrays.&lt;BR /&gt;&lt;FONT color="#800000"&gt;In this time, many arrays didn't accept any values.&lt;/FONT&gt;&lt;/LI&gt;
&lt;LI&gt;&amp;nbsp;&lt;/LI&gt;
&lt;LI&gt;Changing parameter arrays names.&lt;/LI&gt;
&lt;LI&gt;&amp;nbsp;&lt;/LI&gt;
&lt;LI&gt;Arrays' script manipulations were defined in "&lt;STRONG&gt;Parameter Script&lt;/STRONG&gt;" &amp;amp; "&lt;STRONG&gt;Master Script&lt;/STRONG&gt;"&lt;/LI&gt;
&lt;/UL&gt;
&lt;S&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;U&gt;&lt;/U&gt;&lt;S&gt;&lt;U&gt;&lt;U&gt;&lt;/U&gt;&lt;/U&gt;&lt;/S&gt;Request:&lt;BR /&gt;A sure fire method for parameter array value update.&lt;/S&gt;&lt;/DIV&gt;</description>
      <pubDate>Mon, 26 Sep 2022 20:44:28 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/GDL/Problem-Persistent-Parameter-Arrays-Values-amp-deletion/m-p/277319#M4879</guid>
      <dc:creator>Nader Belal</dc:creator>
      <dc:date>2022-09-26T20:44:28Z</dc:date>
    </item>
    <item>
      <title>Re: Problem: Persistent Parameter Arrays Values &amp; deletion</title>
      <link>https://community.graphisoft.com/t5/GDL/Problem-Persistent-Parameter-Arrays-Values-amp-deletion/m-p/277320#M4880</link>
      <description>Have you tried re-declaring the arrays?&lt;BR /&gt;
&lt;BR /&gt;
The process for flexible-length arrays:&lt;BR /&gt;
&lt;BR /&gt;
1. Declare a temporary array&lt;BR /&gt;
2. Fill the temporary array with the parameter array&lt;BR /&gt;
3. Re-declare the parameter array&lt;BR /&gt;
4. VALUES commands to be listed after this declaration, not before&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
Sample code, where 'size1' is an integer parameter, and myArray is a length parameter, activated as an array.&lt;BR /&gt;

&lt;PRE&gt;IF GLOB_MODPAR_NAME = "size1" THEN
	DIM _tempArray []
	_tempArray = myArray
	
	DIM myArray []
	FOR ii = 1 to size1
		IF ii &amp;gt; vardim1(_tempArray) THEN
			_value = 0
		ELSE
			_value = _tempArray[ii]
		ENDIF
		myArray[ii] = _value
	NEXT ii
	PARAMETERS myArray = myArray
ENDIF

VALUES "myArray" RANGE (0, )&lt;/PRE&gt;</description>
      <pubDate>Sat, 05 Sep 2020 10:06:13 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/GDL/Problem-Persistent-Parameter-Arrays-Values-amp-deletion/m-p/277320#M4880</guid>
      <dc:creator>Bruce</dc:creator>
      <dc:date>2020-09-05T10:06:13Z</dc:date>
    </item>
    <item>
      <title>Re: Problem: Persistent Parameter Arrays Values &amp; deletion</title>
      <link>https://community.graphisoft.com/t5/GDL/Problem-Persistent-Parameter-Arrays-Values-amp-deletion/m-p/277321#M4881</link>
      <description>Hi Moonlight,&lt;BR /&gt;
&lt;BR /&gt;
This code works for me:
&lt;PRE&gt;if GLOB_MODPAR_NAME = "reset" then
	dim ar1[1][1]
	dim ar2[1][1]
	parameters ar1 = ar1, ar2 = ar2
endif
&lt;/PRE&gt;

Maybe if there is another connection between your arrays based on some GLOB_MODPAR_NAME, it might not work as expected.</description>
      <pubDate>Mon, 07 Sep 2020 09:26:17 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/GDL/Problem-Persistent-Parameter-Arrays-Values-amp-deletion/m-p/277321#M4881</guid>
      <dc:creator>Peter Baksa</dc:creator>
      <dc:date>2020-09-07T09:26:17Z</dc:date>
    </item>
  </channel>
</rss>

