<?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 Automatic comparison of details and sections alphabetically in Inventor Programming - iLogic, Macros, AddIns &amp; Apprentice</title>
    <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/automatic-comparison-of-details-and-sections-alphabetically/m-p/9772689#M116395</link>
    <description>&lt;P&gt;Hi to all,&lt;BR /&gt;when generating drawing documentation, it is necessary to work with details and sections. If I find that one of the details or cuts does not suit me and I delete it, then it is not possible to automatically compare the individual designations so that the letters go alphabetically. Is it possible to solve this with the iLogic rule?&lt;BR /&gt;Thanks&lt;/P&gt;</description>
    <pubDate>Mon, 28 Sep 2020 17:35:36 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2020-09-28T17:35:36Z</dc:date>
    <item>
      <title>Automatic comparison of details and sections alphabetically</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/automatic-comparison-of-details-and-sections-alphabetically/m-p/9772689#M116395</link>
      <description>&lt;P&gt;Hi to all,&lt;BR /&gt;when generating drawing documentation, it is necessary to work with details and sections. If I find that one of the details or cuts does not suit me and I delete it, then it is not possible to automatically compare the individual designations so that the letters go alphabetically. Is it possible to solve this with the iLogic rule?&lt;BR /&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Mon, 28 Sep 2020 17:35:36 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/automatic-comparison-of-details-and-sections-alphabetically/m-p/9772689#M116395</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-09-28T17:35:36Z</dc:date>
    </item>
    <item>
      <title>Re: Automatic comparison of details and sections alphabetically</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/automatic-comparison-of-details-and-sections-alphabetically/m-p/9773647#M116414</link>
      <description>&lt;P&gt;Hi @Anonymous&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;There's a VBA code posted about this by @Anonymous&lt;/a&gt; here:&lt;/P&gt;
&lt;P&gt;&lt;A href="https://forums.autodesk.com/t5/inventor-ideas/drawings-re-number-detail-amp-section-views/idi-p/6276556" target="_blank"&gt;https://forums.autodesk.com/t5/inventor-ideas/drawings-re-number-detail-amp-section-views/idi-p/6276556&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;As an iLogic rule it'd look something like this &lt;img class="lia-deferred-image lia-image-emoji" src="https://forums.autodesk.com/html/@B4D44A73814D7FC0D950DEDFACB97081/emoticons/1f642.png" alt=":slightly_smiling_face:" title=":slightly_smiling_face:" /&gt;&lt;/P&gt;
&lt;PRE&gt;&lt;SPAN style="color: #ff0000;"&gt;Sub&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;Main&lt;/SPAN&gt;
&lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;oDoc&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;DrawingDocument&lt;/SPAN&gt;
&lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;oSheet&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;Sheet&lt;/SPAN&gt;
&lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;oView&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;DrawingView&lt;/SPAN&gt;
&lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;iter&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Long&lt;/SPAN&gt;

&lt;SPAN style="color: #808080;"&gt;'check if active document is a drawing&lt;/SPAN&gt;
&lt;SPAN style="color: #ff0000;"&gt;If&lt;/SPAN&gt; &lt;SPAN style="color: #800080;"&gt;ThisApplication&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;ActiveDocument&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;DocumentType&lt;/SPAN&gt; &amp;lt;&amp;gt; &lt;SPAN style="color: #800000;"&gt;kDrawingDocumentObject&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Then&lt;/SPAN&gt;
    &lt;SPAN style="color: #ff0000;"&gt;Exit&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Sub&lt;/SPAN&gt;
&lt;SPAN style="color: #ff0000;"&gt;End&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;If&lt;/SPAN&gt;

&lt;SPAN style="color: #800000;"&gt;oDoc&lt;/SPAN&gt; = &lt;SPAN style="color: #800080;"&gt;ThisApplication&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;ActiveDocument&lt;/SPAN&gt;


&lt;SPAN style="color: #800000;"&gt;iter&lt;/SPAN&gt; = 1

&lt;SPAN style="color: #808080;"&gt;'Rename detail and section view identifiers on all sheets&lt;/SPAN&gt;
&lt;SPAN style="color: #ff0000;"&gt;For&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Each&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;oSheet&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;In&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;oDoc&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Sheets&lt;/SPAN&gt;
    &lt;SPAN style="color: #ff0000;"&gt;For&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Each&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;oView&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;In&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;oSheet&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;DrawingViews&lt;/SPAN&gt;
        &lt;SPAN style="color: #ff0000;"&gt;If&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;oView&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;ViewType&lt;/SPAN&gt; = &lt;SPAN style="color: #800000;"&gt;kDetailDrawingViewType&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Or&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;oView&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;ViewType&lt;/SPAN&gt; = &lt;SPAN style="color: #800000;"&gt;kSectionDrawingViewType&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Then&lt;/SPAN&gt;
            &lt;SPAN style="color: #800000;"&gt;oView&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Name&lt;/SPAN&gt; = &lt;SPAN style="color: #800000;"&gt;num2Letter&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;iter&lt;/SPAN&gt;)
            &lt;SPAN style="color: #800000;"&gt;iter&lt;/SPAN&gt; = &lt;SPAN style="color: #800000;"&gt;iter&lt;/SPAN&gt; + 1
            &lt;SPAN style="color: #ff0000;"&gt;If&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;InStr&lt;/SPAN&gt;(1, &lt;SPAN style="color: #800000;"&gt;num2Letter&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;iter&lt;/SPAN&gt;), &lt;SPAN style="color: #008080;"&gt;"I"&lt;/SPAN&gt;) &amp;gt; 0 &lt;SPAN style="color: #ff0000;"&gt;Or&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;InStr&lt;/SPAN&gt;(1, &lt;SPAN style="color: #800000;"&gt;num2Letter&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;iter&lt;/SPAN&gt;), &lt;SPAN style="color: #008080;"&gt;"O"&lt;/SPAN&gt;) &amp;gt; 0 &lt;SPAN style="color: #ff0000;"&gt;Or&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;InStr&lt;/SPAN&gt;(1, &lt;SPAN style="color: #800000;"&gt;num2Letter&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;iter&lt;/SPAN&gt;), &lt;SPAN style="color: #008080;"&gt;"Q"&lt;/SPAN&gt;) &amp;gt; 0 &lt;SPAN style="color: #ff0000;"&gt;Then&lt;/SPAN&gt;
                &lt;SPAN style="color: #800000;"&gt;iter&lt;/SPAN&gt; = &lt;SPAN style="color: #800000;"&gt;iter&lt;/SPAN&gt; + 1
            &lt;SPAN style="color: #ff0000;"&gt;End&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;If&lt;/SPAN&gt;
        &lt;SPAN style="color: #ff0000;"&gt;End&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;If&lt;/SPAN&gt;
    &lt;SPAN style="color: #ff0000;"&gt;Next&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;oView&lt;/SPAN&gt;
&lt;SPAN style="color: #ff0000;"&gt;Next&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;oSheet&lt;/SPAN&gt;


&lt;SPAN style="color: #ff0000;"&gt;End&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Sub&lt;/SPAN&gt;
&lt;SPAN style="color: #ff0000;"&gt;Public&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Function&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;num2Letter&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;num&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Long&lt;/SPAN&gt;) &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;String&lt;/SPAN&gt;
&lt;SPAN style="color: #808080;"&gt;'converts long to corresponding alpha&lt;/SPAN&gt;
&lt;SPAN style="color: #808080;"&gt;'Ex. 1 = A, 28 = AB&lt;/SPAN&gt;

&lt;SPAN style="color: #800000;"&gt;remain&lt;/SPAN&gt; = &lt;SPAN style="color: #800000;"&gt;num&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Mod&lt;/SPAN&gt; 26
&lt;SPAN style="color: #800000;"&gt;whole&lt;/SPAN&gt; = &lt;SPAN style="color: #800000;"&gt;Fix&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;num&lt;/SPAN&gt; / 26)
    
&lt;SPAN style="color: #ff0000;"&gt;If&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;num&lt;/SPAN&gt; &amp;lt; 27 &lt;SPAN style="color: #ff0000;"&gt;Then&lt;/SPAN&gt;
    &lt;SPAN style="color: #ff0000;"&gt;If&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;remain&lt;/SPAN&gt; = 0 &lt;SPAN style="color: #ff0000;"&gt;Then&lt;/SPAN&gt;
        &lt;SPAN style="color: #800000;"&gt;num2Letter&lt;/SPAN&gt; = &lt;SPAN style="color: #008080;"&gt;"Z"&lt;/SPAN&gt;
    &lt;SPAN style="color: #ff0000;"&gt;Else&lt;/SPAN&gt;
        &lt;SPAN style="color: #800000;"&gt;num2Letter&lt;/SPAN&gt; = &lt;SPAN style="color: #800000;"&gt;Chr&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;remain&lt;/SPAN&gt; + 64)
    &lt;SPAN style="color: #ff0000;"&gt;End&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;If&lt;/SPAN&gt;
&lt;SPAN style="color: #ff0000;"&gt;Else&lt;/SPAN&gt;
    &lt;SPAN style="color: #ff0000;"&gt;If&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;remain&lt;/SPAN&gt; = 0 &lt;SPAN style="color: #ff0000;"&gt;Then&lt;/SPAN&gt;
        &lt;SPAN style="color: #800000;"&gt;num2Letter&lt;/SPAN&gt; = &lt;SPAN style="color: #800000;"&gt;Chr&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;whole&lt;/SPAN&gt; + 63) &amp;amp; &lt;SPAN style="color: #008080;"&gt;"Z"&lt;/SPAN&gt;
    &lt;SPAN style="color: #ff0000;"&gt;Else&lt;/SPAN&gt;
        &lt;SPAN style="color: #800000;"&gt;num2Letter&lt;/SPAN&gt; = &lt;SPAN style="color: #800000;"&gt;Chr&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;whole&lt;/SPAN&gt; + 64) &amp;amp; &lt;SPAN style="color: #800000;"&gt;Chr&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;remain&lt;/SPAN&gt; + 64)
    &lt;SPAN style="color: #ff0000;"&gt;End&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;If&lt;/SPAN&gt;
&lt;SPAN style="color: #ff0000;"&gt;End&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;If&lt;/SPAN&gt;

&lt;SPAN style="color: #ff0000;"&gt;End&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Function&lt;/SPAN&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 06:36:40 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/automatic-comparison-of-details-and-sections-alphabetically/m-p/9773647#M116414</guid>
      <dc:creator>JhoelForshav</dc:creator>
      <dc:date>2020-09-29T06:36:40Z</dc:date>
    </item>
    <item>
      <title>Re: Automatic comparison of details and sections alphabetically</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/automatic-comparison-of-details-and-sections-alphabetically/m-p/9774147#M116426</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;thank you, it works great.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 11:07:13 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/automatic-comparison-of-details-and-sections-alphabetically/m-p/9774147#M116426</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-09-29T11:07:13Z</dc:date>
    </item>
  </channel>
</rss>

