<?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 How to control max and min value of a dimension? in Inventor Programming - iLogic, Macros, AddIns &amp; Apprentice</title>
    <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/how-to-control-max-and-min-value-of-a-dimension/m-p/10610140#M128681</link>
    <description>&lt;P&gt;Hi;&lt;/P&gt;&lt;P&gt;I would like to control one of my parameter in Inventor. (in equation or ilogic rule)&lt;/P&gt;&lt;P&gt;For example&amp;nbsp; my parameter is A2 and I want to limit that parameter within 200 and 500&lt;/P&gt;&lt;P&gt;200&amp;lt;A2&amp;lt;500&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 09 Sep 2021 08:03:12 GMT</pubDate>
    <dc:creator>ikilic1461</dc:creator>
    <dc:date>2021-09-09T08:03:12Z</dc:date>
    <item>
      <title>How to control max and min value of a dimension?</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/how-to-control-max-and-min-value-of-a-dimension/m-p/10610140#M128681</link>
      <description>&lt;P&gt;Hi;&lt;/P&gt;&lt;P&gt;I would like to control one of my parameter in Inventor. (in equation or ilogic rule)&lt;/P&gt;&lt;P&gt;For example&amp;nbsp; my parameter is A2 and I want to limit that parameter within 200 and 500&lt;/P&gt;&lt;P&gt;200&amp;lt;A2&amp;lt;500&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 09 Sep 2021 08:03:12 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/how-to-control-max-and-min-value-of-a-dimension/m-p/10610140#M128681</guid>
      <dc:creator>ikilic1461</dc:creator>
      <dc:date>2021-09-09T08:03:12Z</dc:date>
    </item>
    <item>
      <title>Re: How to control max and min value of a dimension?</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/how-to-control-max-and-min-value-of-a-dimension/m-p/10610715#M128688</link>
      <description>&lt;P&gt;Hi &lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/7106668"&gt;@ikilic1461&lt;/a&gt;.&amp;nbsp; Here is some iLogic code you can use as a 'local' rule in that document.&amp;nbsp; If the parameter's name is "A2", then when you use that unquoted name within a 'local' rule, it will trigger that rule to run any time the value of that parameter changes.&amp;nbsp; Then this rule should effectively &amp;amp; automatically keep the value of that parameter within the range specified.&amp;nbsp; However, keep in mind that raw numbers in iLogic that represent measurements, will automatically be understood by Inventor as 'database' units (metric base units &amp;gt;&amp;gt;&amp;gt; length = centimeters, angle = radians, mass = grams, etc.)&amp;nbsp; So you may have to play with the numbers within the rule to get the 'units' to work out as you need them to.&lt;/P&gt;
&lt;P&gt;Here's the iLogic rule code:&lt;/P&gt;
&lt;LI-CODE lang="general"&gt;If A2 &amp;lt; 200 Then
	MsgBox("A2 must be within 200 to 500." &amp;amp; vbCrLf &amp;amp; _
	"Lower values will be set to 200.",vbInformation,"Parameter Police")
	A2 = 200
ElseIf A2 &amp;gt; 500 Then
	MsgBox("A2 must be within 200 to 500." &amp;amp; vbCrLf &amp;amp; _
	"Higher values will be set to 500.",vbInformation,"Parameter Police")
	A2 = 500
End If&lt;/LI-CODE&gt;
&lt;P&gt;If this solved your problem, or answered your question, please click &lt;SPAN style="background-color: green; color: white;"&gt;&lt;STRONG&gt;ACCEPT SOLUTION&lt;/STRONG&gt;&lt;/SPAN&gt;.&lt;BR /&gt;Or, if this helped you, please click (LIKE or KUDOS) &lt;SPAN&gt;&lt;img class="lia-deferred-image lia-image-emoji" src="https://forums.autodesk.com/html/@7401B55A0A518861312A0F851CD29320/emoticons/1f44d.png" alt=":thumbs_up:" title=":thumbs_up:" /&gt;&lt;/SPAN&gt;.&lt;/P&gt;
&lt;P&gt;If you want and have time, I would appreciate your Vote(s) for &lt;A href="https://forums.autodesk.com/t5/forums/recentpostspage/post-type/message/interaction-style/idea/user-id/7812054/" target="_blank"&gt;My IDEAS &lt;SPAN&gt;&lt;img class="lia-deferred-image lia-image-emoji" src="https://forums.autodesk.com/html/@B166FEBB95D67CFA84899D32D8E17FC1/emoticons/1f4a1.png" alt=":light_bulb:" title=":light_bulb:" /&gt;&lt;/SPAN&gt;&lt;/A&gt;or you can Explore &lt;A href="https://knowledge.autodesk.com/profile/LTSUSR7HXMSAE/articles" target="_blank"&gt;My CONTRIBUTIONS &lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 09 Sep 2021 12:23:20 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/how-to-control-max-and-min-value-of-a-dimension/m-p/10610715#M128688</guid>
      <dc:creator>WCrihfield</dc:creator>
      <dc:date>2021-09-09T12:23:20Z</dc:date>
    </item>
    <item>
      <title>Re: How to control max and min value of a dimension?</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/how-to-control-max-and-min-value-of-a-dimension/m-p/10610962#M128693</link>
      <description>&lt;P&gt;Thank you. It worked well.&lt;/P&gt;</description>
      <pubDate>Thu, 09 Sep 2021 13:41:32 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/how-to-control-max-and-min-value-of-a-dimension/m-p/10610962#M128693</guid>
      <dc:creator>ikilic1461</dc:creator>
      <dc:date>2021-09-09T13:41:32Z</dc:date>
    </item>
  </channel>
</rss>

