<?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: How can  write rule for Sheet metal assembly export dxf  with  file name  Part Number_sheet thickness_quantity in Inventor Programming - iLogic, Macros, AddIns &amp; Apprentice</title>
    <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/how-can-write-rule-for-sheet-metal-assembly-export-dxf-with-file/m-p/9898068#M118534</link>
    <description>&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;You can try the next rule. I did have some problem with getting the qty. but the rest should work.&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;doc&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;AssemblyDocument&lt;/SPAN&gt; = &lt;SPAN style="color: #800080;"&gt;ThisDoc&lt;/SPAN&gt;.&lt;SPAN style="color: #800080;"&gt;Document&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;oDoc&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;Document&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;In&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;doc&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;AllReferencedDocuments&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: #800000;"&gt;SubType&lt;/SPAN&gt; &amp;lt;&amp;gt; &lt;SPAN style="color: #008080;"&gt;"{9C464203-9BAE-11D3-8BAD-0060B0CE6BB4}"&lt;/SPAN&gt;) &lt;SPAN style="color: #ff0000;"&gt;Then&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Continue&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;For&lt;/SPAN&gt;

        &lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;fileName&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: #800000;"&gt;getFileName&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;oDoc&lt;/SPAN&gt;)

        &lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;SheetMetalComponentDefinition&lt;/SPAN&gt; = &lt;SPAN style="color: #800000;"&gt;oDoc&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;ComponentDefinition&lt;/SPAN&gt;
        &lt;SPAN style="color: #ff0000;"&gt;If&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;HasFlatPattern&lt;/SPAN&gt; = &lt;SPAN style="color: #ff0000;"&gt;False&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Then&lt;/SPAN&gt;
            &lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Unfold&lt;/SPAN&gt;()
        &lt;SPAN style="color: #ff0000;"&gt;Else&lt;/SPAN&gt;
            &lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;FlatPattern&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Edit&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;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;sOut&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: #008080;"&gt;"FLAT PATTERN DXF?AcadVersion=2000&amp;amp;BendUpLayerColor=0;0;255&amp;amp;BendDownLayerColor=0;0;255&amp;amp;InvisibleLayers=IV_TANGENT"&lt;/SPAN&gt;
        &lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;DataIO&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;WriteDataToFile&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;sOut&lt;/SPAN&gt;, &lt;SPAN style="color: #800000;"&gt;fileName&lt;/SPAN&gt;)
		&lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;FlatPattern&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;ExitEdit&lt;/SPAN&gt;()
    &lt;SPAN style="color: #ff0000;"&gt;Next&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;Private&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Function&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;getFileName&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;PartDocument&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: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;fileNameDoc&lt;/SPAN&gt; = &lt;SPAN style="color: #800000;"&gt;System&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;IO&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Path&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;GetFileName&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;oDoc&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;FullFileName&lt;/SPAN&gt;)
    &lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;partNumber&lt;/SPAN&gt; = &lt;SPAN style="color: #800080;"&gt;iProperties&lt;/SPAN&gt;.&lt;SPAN style="color: #800080;"&gt;Value&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;fileNameDoc&lt;/SPAN&gt;, &lt;SPAN style="color: #008080;"&gt;"Project"&lt;/SPAN&gt;, &lt;SPAN style="color: #008080;"&gt;"Part Number"&lt;/SPAN&gt;)
	&lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;thickness&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Double&lt;/SPAN&gt; = &lt;SPAN style="color: #800080;"&gt;Parameter&lt;/SPAN&gt;(&lt;SPAN style="color: #008080;"&gt;"flatpattern.ipt"&lt;/SPAN&gt;, &lt;SPAN style="color: #008080;"&gt;"Thickness"&lt;/SPAN&gt;)
	&lt;SPAN style="color: #800000;"&gt;thickness&lt;/SPAN&gt; = &lt;SPAN style="color: #800000;"&gt;Math&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Round&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;thickness&lt;/SPAN&gt; * 10)
    &lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;newFileName&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: #ff0000;"&gt;String&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Format&lt;/SPAN&gt;(&lt;SPAN style="color: #008080;"&gt;"{0}_{1}"&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;partNumber&lt;/SPAN&gt;, &lt;SPAN style="color: #800000;"&gt;thickness&lt;/SPAN&gt;)
    &lt;SPAN style="color: #ff0000;"&gt;Return&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;IO&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Path&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Combine&lt;/SPAN&gt;(&lt;SPAN style="color: #008080;"&gt;"c:\temp\"&lt;/SPAN&gt;, &lt;SPAN style="color: #800000;"&gt;newFileName&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;</description>
    <pubDate>Thu, 26 Nov 2020 21:33:51 GMT</pubDate>
    <dc:creator>JelteDeJong</dc:creator>
    <dc:date>2020-11-26T21:33:51Z</dc:date>
    <item>
      <title>How can  write rule for Sheet metal assembly export dxf  with  file name  Part Number_sheet thickness_quantity</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/how-can-write-rule-for-sheet-metal-assembly-export-dxf-with-file/m-p/9897915#M118532</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;I want&amp;nbsp; rule of&amp;nbsp;Sheet metal assembly export dxf with Blue Bend line&amp;nbsp; but, File name is part Number_Thickness_Quantity.&lt;/P&gt;&lt;P&gt;İt is possible by rule&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Thu, 26 Nov 2020 19:41:07 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/how-can-write-rule-for-sheet-metal-assembly-export-dxf-with-file/m-p/9897915#M118532</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-11-26T19:41:07Z</dc:date>
    </item>
    <item>
      <title>Re: How can  write rule for Sheet metal assembly export dxf  with  file name  Part Number_sheet thickness_quantity</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/how-can-write-rule-for-sheet-metal-assembly-export-dxf-with-file/m-p/9898068#M118534</link>
      <description>&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;You can try the next rule. I did have some problem with getting the qty. but the rest should work.&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;doc&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;AssemblyDocument&lt;/SPAN&gt; = &lt;SPAN style="color: #800080;"&gt;ThisDoc&lt;/SPAN&gt;.&lt;SPAN style="color: #800080;"&gt;Document&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;oDoc&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;Document&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;In&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;doc&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;AllReferencedDocuments&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: #800000;"&gt;SubType&lt;/SPAN&gt; &amp;lt;&amp;gt; &lt;SPAN style="color: #008080;"&gt;"{9C464203-9BAE-11D3-8BAD-0060B0CE6BB4}"&lt;/SPAN&gt;) &lt;SPAN style="color: #ff0000;"&gt;Then&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Continue&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;For&lt;/SPAN&gt;

        &lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;fileName&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: #800000;"&gt;getFileName&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;oDoc&lt;/SPAN&gt;)

        &lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;SheetMetalComponentDefinition&lt;/SPAN&gt; = &lt;SPAN style="color: #800000;"&gt;oDoc&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;ComponentDefinition&lt;/SPAN&gt;
        &lt;SPAN style="color: #ff0000;"&gt;If&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;HasFlatPattern&lt;/SPAN&gt; = &lt;SPAN style="color: #ff0000;"&gt;False&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Then&lt;/SPAN&gt;
            &lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Unfold&lt;/SPAN&gt;()
        &lt;SPAN style="color: #ff0000;"&gt;Else&lt;/SPAN&gt;
            &lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;FlatPattern&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Edit&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;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;sOut&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: #008080;"&gt;"FLAT PATTERN DXF?AcadVersion=2000&amp;amp;BendUpLayerColor=0;0;255&amp;amp;BendDownLayerColor=0;0;255&amp;amp;InvisibleLayers=IV_TANGENT"&lt;/SPAN&gt;
        &lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;DataIO&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;WriteDataToFile&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;sOut&lt;/SPAN&gt;, &lt;SPAN style="color: #800000;"&gt;fileName&lt;/SPAN&gt;)
		&lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;FlatPattern&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;ExitEdit&lt;/SPAN&gt;()
    &lt;SPAN style="color: #ff0000;"&gt;Next&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;Private&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Function&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;getFileName&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;PartDocument&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: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;fileNameDoc&lt;/SPAN&gt; = &lt;SPAN style="color: #800000;"&gt;System&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;IO&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Path&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;GetFileName&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;oDoc&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;FullFileName&lt;/SPAN&gt;)
    &lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;partNumber&lt;/SPAN&gt; = &lt;SPAN style="color: #800080;"&gt;iProperties&lt;/SPAN&gt;.&lt;SPAN style="color: #800080;"&gt;Value&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;fileNameDoc&lt;/SPAN&gt;, &lt;SPAN style="color: #008080;"&gt;"Project"&lt;/SPAN&gt;, &lt;SPAN style="color: #008080;"&gt;"Part Number"&lt;/SPAN&gt;)
	&lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;thickness&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Double&lt;/SPAN&gt; = &lt;SPAN style="color: #800080;"&gt;Parameter&lt;/SPAN&gt;(&lt;SPAN style="color: #008080;"&gt;"flatpattern.ipt"&lt;/SPAN&gt;, &lt;SPAN style="color: #008080;"&gt;"Thickness"&lt;/SPAN&gt;)
	&lt;SPAN style="color: #800000;"&gt;thickness&lt;/SPAN&gt; = &lt;SPAN style="color: #800000;"&gt;Math&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Round&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;thickness&lt;/SPAN&gt; * 10)
    &lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;newFileName&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: #ff0000;"&gt;String&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Format&lt;/SPAN&gt;(&lt;SPAN style="color: #008080;"&gt;"{0}_{1}"&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;partNumber&lt;/SPAN&gt;, &lt;SPAN style="color: #800000;"&gt;thickness&lt;/SPAN&gt;)
    &lt;SPAN style="color: #ff0000;"&gt;Return&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;IO&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Path&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Combine&lt;/SPAN&gt;(&lt;SPAN style="color: #008080;"&gt;"c:\temp\"&lt;/SPAN&gt;, &lt;SPAN style="color: #800000;"&gt;newFileName&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;</description>
      <pubDate>Thu, 26 Nov 2020 21:33:51 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/how-can-write-rule-for-sheet-metal-assembly-export-dxf-with-file/m-p/9898068#M118534</guid>
      <dc:creator>JelteDeJong</dc:creator>
      <dc:date>2020-11-26T21:33:51Z</dc:date>
    </item>
    <item>
      <title>Re: How can  write rule for Sheet metal assembly export dxf  with  file name  Part Number_sheet thickness_quantity</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/how-can-write-rule-for-sheet-metal-assembly-export-dxf-with-file/m-p/9898593#M118536</link>
      <description>&lt;P&gt;Firtstly Thanks for your repply.&lt;/P&gt;&lt;P&gt;I tried the your code, but it wasnt work.&lt;/P&gt;&lt;P&gt;&lt;EM&gt;"Parameter: The document named "flatpattern.ipt" was not found."&lt;/EM&gt;&amp;nbsp; it show&amp;nbsp; error&lt;/P&gt;</description>
      <pubDate>Fri, 27 Nov 2020 05:28:16 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/how-can-write-rule-for-sheet-metal-assembly-export-dxf-with-file/m-p/9898593#M118536</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-11-27T05:28:16Z</dc:date>
    </item>
    <item>
      <title>Re: How can  write rule for Sheet metal assembly export dxf  with  file name  Part Number_sheet thickness_quantity</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/how-can-write-rule-for-sheet-metal-assembly-export-dxf-with-file/m-p/9900079#M118547</link>
      <description>&lt;P&gt;I guessit was to later yesterday. there i found the bug and fixed it. Check the code below. An other thing that i forgot to mention. i multiply the thickness by 10. I did that because its better if you dont use points in file names. For example if your part would be 1.5mm thick you would get a file name like "PartNumber_1.5.dxf". this code will translate that to "PartNumber_15.dxf"&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;doc&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;AssemblyDocument&lt;/SPAN&gt; = &lt;SPAN style="color: #800080;"&gt;ThisDoc&lt;/SPAN&gt;.&lt;SPAN style="color: #800080;"&gt;Document&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;oDoc&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;Document&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;In&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;doc&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;AllReferencedDocuments&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: #800000;"&gt;SubType&lt;/SPAN&gt; &amp;lt;&amp;gt; &lt;SPAN style="color: #008080;"&gt;"{9C464203-9BAE-11D3-8BAD-0060B0CE6BB4}"&lt;/SPAN&gt;) &lt;SPAN style="color: #ff0000;"&gt;Then&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Continue&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;For&lt;/SPAN&gt;

        &lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;fileName&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: #800000;"&gt;getFileName&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;oDoc&lt;/SPAN&gt;)

        &lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;SheetMetalComponentDefinition&lt;/SPAN&gt; = &lt;SPAN style="color: #800000;"&gt;oDoc&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;ComponentDefinition&lt;/SPAN&gt;
        &lt;SPAN style="color: #ff0000;"&gt;If&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;HasFlatPattern&lt;/SPAN&gt; = &lt;SPAN style="color: #ff0000;"&gt;False&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Then&lt;/SPAN&gt;
            &lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Unfold&lt;/SPAN&gt;()
        &lt;SPAN style="color: #ff0000;"&gt;Else&lt;/SPAN&gt;
            &lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;FlatPattern&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Edit&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;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;sOut&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: #008080;"&gt;"FLAT PATTERN DXF?AcadVersion=2000&amp;amp;BendUpLayerColor=0;0;255&amp;amp;BendDownLayerColor=0;0;255&amp;amp;InvisibleLayers=IV_TANGENT"&lt;/SPAN&gt;
        &lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;DataIO&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;WriteDataToFile&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;sOut&lt;/SPAN&gt;, &lt;SPAN style="color: #800000;"&gt;fileName&lt;/SPAN&gt;)
	&lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;FlatPattern&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;ExitEdit&lt;/SPAN&gt;()
    &lt;SPAN style="color: #ff0000;"&gt;Next&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;Private&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Function&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;getFileName&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;PartDocument&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: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;fileNameDoc&lt;/SPAN&gt; = &lt;SPAN style="color: #800000;"&gt;System&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;IO&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Path&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;GetFileName&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;oDoc&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;FullFileName&lt;/SPAN&gt;)
    &lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;partNumber&lt;/SPAN&gt; = &lt;SPAN style="color: #800080;"&gt;iProperties&lt;/SPAN&gt;.&lt;SPAN style="color: #800080;"&gt;Value&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;fileNameDoc&lt;/SPAN&gt;, &lt;SPAN style="color: #008080;"&gt;"Project"&lt;/SPAN&gt;, &lt;SPAN style="color: #008080;"&gt;"Part Number"&lt;/SPAN&gt;)
    &lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;thickness&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Double&lt;/SPAN&gt; = &lt;SPAN style="color: #800080;"&gt;Parameter&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;fileNameDoc&lt;/SPAN&gt;, &lt;SPAN style="color: #008080;"&gt;"Thickness"&lt;/SPAN&gt;)
    &lt;SPAN style="color: #800000;"&gt;thickness&lt;/SPAN&gt; = &lt;SPAN style="color: #800000;"&gt;Math&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Round&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;thickness&lt;/SPAN&gt; * 10)
    &lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;newFileName&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: #ff0000;"&gt;String&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Format&lt;/SPAN&gt;(&lt;SPAN style="color: #008080;"&gt;"{0}_{1}"&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;partNumber&lt;/SPAN&gt;, &lt;SPAN style="color: #800000;"&gt;thickness&lt;/SPAN&gt;)
    &lt;SPAN style="color: #ff0000;"&gt;Return&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;IO&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Path&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Combine&lt;/SPAN&gt;(&lt;SPAN style="color: #008080;"&gt;"c:\temp\"&lt;/SPAN&gt;, &lt;SPAN style="color: #800000;"&gt;newFileName&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>Fri, 27 Nov 2020 19:48:02 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/how-can-write-rule-for-sheet-metal-assembly-export-dxf-with-file/m-p/9900079#M118547</guid>
      <dc:creator>JelteDeJong</dc:creator>
      <dc:date>2020-11-27T19:48:02Z</dc:date>
    </item>
    <item>
      <title>Re: How can  write rule for Sheet metal assembly export dxf  with  file name  Part Number_sheet thickness_quantity</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/how-can-write-rule-for-sheet-metal-assembly-export-dxf-with-file/m-p/9906092#M118625</link>
      <description>&lt;P&gt;Thanks for your attentions.&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/5011186"&gt;@JelteDeJong&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The your rule give:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Error in rule: dxf, in document: 0001-0.iam&lt;/P&gt;&lt;P&gt;c (Exception from HRESULT: 0x80004005 (E_FAIL))&lt;/P&gt;&lt;P&gt;&amp;nbsp;More İnfo&lt;/P&gt;&lt;P&gt;System.Runtime.InteropServices.COMException (0x80004005): System.Runtime.InteropServices.COMException (0x80004005): Belirtilmemiş hata (Exception from HRESULT: 0x80004005 (E_FAIL))&lt;BR /&gt;at System.RuntimeType.ForwardCallToInvokeMember(String memberName, BindingFlags flags, Object target, Int32[] aWrapperTypes, MessageData&amp;amp; msgData)&lt;BR /&gt;at Inventor.FlatPattern.Edit()&lt;BR /&gt;at ThisRule.Main()&lt;BR /&gt;at Autodesk.iLogic.Exec.AppDomExec.ExecRuleInAssembly(Assembly assem)&lt;BR /&gt;at iLogic.RuleEvalContainer.ExecRuleEval(String execRule) (Exception from HRESULT: 0x80004005 (E_FAIL))&lt;BR /&gt;at System.RuntimeType.ForwardCallToInvokeMember(String memberName, BindingFlags flags, Object target, Int32[] aWrapperTypes, MessageData&amp;amp; msgData)&lt;BR /&gt;at Inventor.FlatPattern.Edit()&lt;BR /&gt;at ThisRule.Main()&lt;BR /&gt;at Autodesk.iLogic.Exec.AppDomExec.ExecRuleInAssembly(Assembly assem)&lt;BR /&gt;at iLogic.RuleEvalContainer.ExecRuleEval(String execRule)&lt;/P&gt;&lt;DIV&gt;&lt;DIV class="gtx-trans-icon"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Tue, 01 Dec 2020 05:41:29 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/how-can-write-rule-for-sheet-metal-assembly-export-dxf-with-file/m-p/9906092#M118625</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-12-01T05:41:29Z</dc:date>
    </item>
    <item>
      <title>Re: How can  write rule for Sheet metal assembly export dxf  with  file name  Part Number_sheet thickness_quantity</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/how-can-write-rule-for-sheet-metal-assembly-export-dxf-with-file/m-p/9907782#M118643</link>
      <description>&lt;P&gt;That message doesn't say much. So that does not help. but i added a try/catch block. this will show the file that is creating the problem. maybe it helps. try this rule.&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;doc&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;AssemblyDocument&lt;/SPAN&gt; = &lt;SPAN style="color: #800080;"&gt;ThisDoc&lt;/SPAN&gt;.&lt;SPAN style="color: #800080;"&gt;Document&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;oDoc&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;Document&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;In&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;doc&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;AllReferencedDocuments&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: #800000;"&gt;SubType&lt;/SPAN&gt; &amp;lt;&amp;gt; &lt;SPAN style="color: #008080;"&gt;"{9C464203-9BAE-11D3-8BAD-0060B0CE6BB4}"&lt;/SPAN&gt;) &lt;SPAN style="color: #ff0000;"&gt;Then&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Continue&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;For&lt;/SPAN&gt;
		
		&lt;SPAN style="color: #ff0000;"&gt;Try&lt;/SPAN&gt;
			&lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;fileName&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: #800000;"&gt;getFileName&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;oDoc&lt;/SPAN&gt;)

	        &lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;SheetMetalComponentDefinition&lt;/SPAN&gt; = &lt;SPAN style="color: #800000;"&gt;oDoc&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;ComponentDefinition&lt;/SPAN&gt;
	        &lt;SPAN style="color: #ff0000;"&gt;If&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;HasFlatPattern&lt;/SPAN&gt; = &lt;SPAN style="color: #ff0000;"&gt;False&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Then&lt;/SPAN&gt;
	            &lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Unfold&lt;/SPAN&gt;()
	        &lt;SPAN style="color: #ff0000;"&gt;Else&lt;/SPAN&gt;
	            &lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;FlatPattern&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Edit&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;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;sOut&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: #008080;"&gt;"FLAT PATTERN DXF?AcadVersion=2000&amp;amp;BendUpLayerColor=0;0;255&amp;amp;BendDownLayerColor=0;0;255&amp;amp;InvisibleLayers=IV_TANGENT"&lt;/SPAN&gt;
	        &lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;DataIO&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;WriteDataToFile&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;sOut&lt;/SPAN&gt;, &lt;SPAN style="color: #800000;"&gt;fileName&lt;/SPAN&gt;)
			&lt;SPAN style="color: #800000;"&gt;oCompDef&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;FlatPattern&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;ExitEdit&lt;/SPAN&gt;()
        &lt;SPAN style="color: #ff0000;"&gt;Catch&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;ex&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;Exception&lt;/SPAN&gt;
			&lt;SPAN style="color: #800000;"&gt;MsgBox&lt;/SPAN&gt;(&lt;SPAN style="color: #008080;"&gt;"Exception was thrown while exporting file: "&lt;/SPAN&gt; &amp;amp; &lt;SPAN style="color: #800000;"&gt;oDoc&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;FullDocumentName&lt;/SPAN&gt; )
        &lt;SPAN style="color: #ff0000;"&gt;End&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Try&lt;/SPAN&gt;
    &lt;SPAN style="color: #ff0000;"&gt;Next&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;Private&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Function&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;getFileName&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;PartDocument&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: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;fileNameDoc&lt;/SPAN&gt; = &lt;SPAN style="color: #800000;"&gt;System&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;IO&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Path&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;GetFileName&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;oDoc&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;FullFileName&lt;/SPAN&gt;)
    &lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;partNumber&lt;/SPAN&gt; = &lt;SPAN style="color: #800080;"&gt;iProperties&lt;/SPAN&gt;.&lt;SPAN style="color: #800080;"&gt;Value&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;fileNameDoc&lt;/SPAN&gt;, &lt;SPAN style="color: #008080;"&gt;"Project"&lt;/SPAN&gt;, &lt;SPAN style="color: #008080;"&gt;"Part Number"&lt;/SPAN&gt;)
    &lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;thickness&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;As&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;Double&lt;/SPAN&gt; = &lt;SPAN style="color: #800080;"&gt;Parameter&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;fileNameDoc&lt;/SPAN&gt;, &lt;SPAN style="color: #008080;"&gt;"Thickness"&lt;/SPAN&gt;)
    &lt;SPAN style="color: #800000;"&gt;thickness&lt;/SPAN&gt; = &lt;SPAN style="color: #800000;"&gt;Math&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Round&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;thickness&lt;/SPAN&gt; * 10)
    &lt;SPAN style="color: #ff0000;"&gt;Dim&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;newFileName&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: #ff0000;"&gt;String&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Format&lt;/SPAN&gt;(&lt;SPAN style="color: #008080;"&gt;"{0}_{1}"&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;partNumber&lt;/SPAN&gt;, &lt;SPAN style="color: #800000;"&gt;thickness&lt;/SPAN&gt;)
    &lt;SPAN style="color: #ff0000;"&gt;Return&lt;/SPAN&gt; &lt;SPAN style="color: #800000;"&gt;IO&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Path&lt;/SPAN&gt;.&lt;SPAN style="color: #800000;"&gt;Combine&lt;/SPAN&gt;(&lt;SPAN style="color: #008080;"&gt;"c:\temp\"&lt;/SPAN&gt;, &lt;SPAN style="color: #800000;"&gt;newFileName&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, 01 Dec 2020 19:56:58 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/how-can-write-rule-for-sheet-metal-assembly-export-dxf-with-file/m-p/9907782#M118643</guid>
      <dc:creator>JelteDeJong</dc:creator>
      <dc:date>2020-12-01T19:56:58Z</dc:date>
    </item>
  </channel>
</rss>

