<?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: Tips for saving writing code in GDL</title>
    <link>https://community.graphisoft.com/t5/GDL/Tips-for-saving-writing-code/m-p/341423#M1911</link>
    <description>&lt;P&gt;Thank you, I will test it as soon as I get a chance. &lt;span class="lia-unicode-emoji" title=":smiling_face_with_smiling_eyes:"&gt;😊&lt;/span&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 16 Jun 2022 05:02:40 GMT</pubDate>
    <dc:creator>jc4d</dc:creator>
    <dc:date>2022-06-16T05:02:40Z</dc:date>
    <item>
      <title>Tips for saving writing code</title>
      <link>https://community.graphisoft.com/t5/GDL/Tips-for-saving-writing-code/m-p/341045#M1909</link>
      <description>&lt;P&gt;Hello&lt;/P&gt;&lt;P&gt;I have a set of hideparameters that change depending on what option is checked (hope it makes sense)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Here i have an example in the parameter script:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;		IF no_shelf_1 = 1 THEN
			HIDEPARAMETER "ShelfStyles_1"
			HIDEPARAMETER "Shelf_1_Bottom_Limit"
		ENDIF
		IF no_shelf_2 = 1 THEN
			HIDEPARAMETER "ShelfStyles_2"
			HIDEPARAMETER "Shelf_2_Bottom_Limit"
		ENDIF
		IF no_shelf_3 = 1 THEN
			HIDEPARAMETER "ShelfStyles_3"
			HIDEPARAMETER "Shelf_3_Bottom_Limit"
		ENDIF&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;As you can see in the example above, if I need to add more "IF no_shelf_x" then I have to modify the&amp;nbsp;ShelfStyles_3 to&amp;nbsp;ShelfStyles_x and&amp;nbsp; Shelf_3_Bottom_Limit to Shelf_x_Bottom_Limit and it is a real pain to do it by hand.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So my question is if there is a better way to do this using loops for example?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Juan.&lt;/P&gt;</description>
      <pubDate>Mon, 13 Jun 2022 08:53:33 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/GDL/Tips-for-saving-writing-code/m-p/341045#M1909</guid>
      <dc:creator>jc4d</dc:creator>
      <dc:date>2022-06-13T08:53:33Z</dc:date>
    </item>
    <item>
      <title>Re: Tips for saving writing code</title>
      <link>https://community.graphisoft.com/t5/GDL/Tips-for-saving-writing-code/m-p/341068#M1910</link>
      <description>&lt;P&gt;Have "no_shelf" as an array parameter, so you can loop over all indices, then do some string manipulating:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;for i=1 to vardim1(no_shelf)
	if no_shelf[i] then
    	foo = "shelfstyles_" + str("%~", i)
		hideparameter	foo
	endif
next i&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 17 Jun 2022 13:50:11 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/GDL/Tips-for-saving-writing-code/m-p/341068#M1910</guid>
      <dc:creator>runxel</dc:creator>
      <dc:date>2022-06-17T13:50:11Z</dc:date>
    </item>
    <item>
      <title>Re: Tips for saving writing code</title>
      <link>https://community.graphisoft.com/t5/GDL/Tips-for-saving-writing-code/m-p/341423#M1911</link>
      <description>&lt;P&gt;Thank you, I will test it as soon as I get a chance. &lt;span class="lia-unicode-emoji" title=":smiling_face_with_smiling_eyes:"&gt;😊&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 16 Jun 2022 05:02:40 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/GDL/Tips-for-saving-writing-code/m-p/341423#M1911</guid>
      <dc:creator>jc4d</dc:creator>
      <dc:date>2022-06-16T05:02:40Z</dc:date>
    </item>
  </channel>
</rss>

