<?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: update iPART part number as filename in Inventor Programming - iLogic, Macros, AddIns &amp; Apprentice</title>
    <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/update-ipart-part-number-as-filename/m-p/11297463#M140286</link>
    <description>&lt;P&gt;Perhaps a simple solution is to have the file name column as the part number column instead of the normal method where the member column dictates the filename.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;From what I hear the i factory is a writable file and not stored in a library.&amp;nbsp;&lt;BR /&gt;Here is the API help for the &lt;A href="https://help.autodesk.com/view/INVNTOR/2022/ENU/?guid=iPartTableColumn" target="_blank" rel="noopener"&gt;iPart factory&lt;/A&gt;.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 14 Jul 2022 14:16:26 GMT</pubDate>
    <dc:creator>A.Acheson</dc:creator>
    <dc:date>2022-07-14T14:16:26Z</dc:date>
    <item>
      <title>update iPART part number as filename</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/update-ipart-part-number-as-filename/m-p/11295363#M140262</link>
      <description>&lt;P&gt;Hi everyone, I have used this line of code for consistent Part Numbers when saving files:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;iProperties.Value("Project", "Part Number")= ThisDoc.FileName&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;as suggest by autodesk itself: &lt;A href="https://knowledge.autodesk.com/support/inventor/learn-explore/caas/sfdcarticles/sfdcarticles/How-to-update-iProperties-Part-Number-so-that-it-always-reflect-the-current-file-name.html" target="_blank"&gt;https://knowledge.autodesk.com/support/inventor/learn-explore/caas/sfdcarticles/sfdcarticles/How-to-update-iProperties-Part-Number-so-that-it-always-reflect-the-current-file-name.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The problem is when I use this rule in an iPart it breaks the part Number because of Index.&lt;/P&gt;&lt;P&gt;Is there an easy fix to this code?&lt;/P&gt;</description>
      <pubDate>Wed, 13 Jul 2022 18:17:01 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/update-ipart-part-number-as-filename/m-p/11295363#M140262</guid>
      <dc:creator>vitor2HXBF</dc:creator>
      <dc:date>2022-07-13T18:17:01Z</dc:date>
    </item>
    <item>
      <title>Re: update iPART part number as filename</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/update-ipart-part-number-as-filename/m-p/11295935#M140267</link>
      <description>&lt;P&gt;Can you explain where you need the filename changed? Is the iPart factory in a library or in your workspace folder? The iPart member name or partnumber can be set in the iPart factory table. No ilogic should be needed. If you can supply some more information with images etc the answer can correctly target your request.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 14 Jul 2022 00:12:10 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/update-ipart-part-number-as-filename/m-p/11295935#M140267</guid>
      <dc:creator>A.Acheson</dc:creator>
      <dc:date>2022-07-14T00:12:10Z</dc:date>
    </item>
    <item>
      <title>Re: update iPART part number as filename</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/update-ipart-part-number-as-filename/m-p/11297045#M140280</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/7946284"&gt;@A.Acheson&lt;/a&gt;&amp;nbsp;&amp;nbsp;I want to prevent others from changing the filename without changing the iProperties partnumber, this worked as the link suggested&amp;nbsp;&amp;nbsp;"How to update iProperties Part Number so that it always reflect the current file name". the exception is when i try saving an iPart.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;There is nothing much to say besides repeating the article steps. Then follow this steps from your Part:&lt;/P&gt;&lt;P&gt;Save as filename.ipt &amp;gt;&amp;nbsp;Manage &amp;gt; Create iPart &amp;gt; insert Row&amp;nbsp;&lt;/P&gt;&lt;P&gt;Now the child PartNumber is filename-01, filename-02.&lt;/P&gt;&lt;P&gt;Run article's Rule0 (&lt;STRONG&gt;iProperties.Value("Project", "Part Number")= ThisDoc.FileName)&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Now the child PartNumber is "filename" and not "filename-01".&lt;/P&gt;&lt;P&gt;if you try to change the iPart child in the Table, this is the prompt:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="vitor2HXBF_1-1657798470929.png" style="width: 600px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1091669iBF68E9B2E0BB839D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="vitor2HXBF_1-1657798470929.png" alt="vitor2HXBF_1-1657798470929.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt; I work aroud the Rule0 to check if is iPart then it will not override the PartNumber:&lt;/P&gt;&lt;PRE&gt;	&lt;SPAN&gt;oPartDoc&lt;/SPAN&gt; = &lt;SPAN&gt;ThisApplication&lt;/SPAN&gt;.&lt;SPAN&gt;ActiveDocument&lt;/SPAN&gt;    
	&lt;SPAN&gt;If&lt;/SPAN&gt; &lt;SPAN&gt;oPartDoc&lt;/SPAN&gt;.&lt;SPAN&gt;ComponentDefinition&lt;/SPAN&gt;.&lt;SPAN&gt;IsiPartFactory&lt;/SPAN&gt; _
	&lt;SPAN&gt;Or&lt;/SPAN&gt; &lt;SPAN&gt;oPartDoc&lt;/SPAN&gt;.&lt;SPAN&gt;ComponentDefinition&lt;/SPAN&gt;.&lt;SPAN&gt;IsiPartMember&lt;/SPAN&gt; &lt;SPAN&gt;Then&lt;/SPAN&gt;
	
	&lt;SPAN&gt;'Basically I want this&lt;/SPAN&gt;
	
	&lt;SPAN&gt;Else&lt;/SPAN&gt;
	&lt;SPAN&gt;iProperties&lt;/SPAN&gt;.&lt;SPAN&gt;Value&lt;/SPAN&gt;(&lt;SPAN&gt;"Project"&lt;/SPAN&gt;, &lt;SPAN&gt;"Part Number"&lt;/SPAN&gt;) = &lt;SPAN&gt;ThisDoc&lt;/SPAN&gt;.&lt;SPAN&gt;FileName&lt;/SPAN&gt;
	&lt;SPAN&gt;End&lt;/SPAN&gt; &lt;SPAN&gt;If&lt;BR /&gt;&lt;/SPAN&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;I want that commented line of code that considers Indexes&lt;/P&gt;</description>
      <pubDate>Thu, 14 Jul 2022 11:38:30 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/update-ipart-part-number-as-filename/m-p/11297045#M140280</guid>
      <dc:creator>vitor2HXBF</dc:creator>
      <dc:date>2022-07-14T11:38:30Z</dc:date>
    </item>
    <item>
      <title>Re: update iPART part number as filename</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/update-ipart-part-number-as-filename/m-p/11297463#M140286</link>
      <description>&lt;P&gt;Perhaps a simple solution is to have the file name column as the part number column instead of the normal method where the member column dictates the filename.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;From what I hear the i factory is a writable file and not stored in a library.&amp;nbsp;&lt;BR /&gt;Here is the API help for the &lt;A href="https://help.autodesk.com/view/INVNTOR/2022/ENU/?guid=iPartTableColumn" target="_blank" rel="noopener"&gt;iPart factory&lt;/A&gt;.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 14 Jul 2022 14:16:26 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/update-ipart-part-number-as-filename/m-p/11297463#M140286</guid>
      <dc:creator>A.Acheson</dc:creator>
      <dc:date>2022-07-14T14:16:26Z</dc:date>
    </item>
  </channel>
</rss>

