<?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 simple ilogic to difference between titles in Inventor Programming Forum</title>
    <link>https://forums.autodesk.com/t5/inventor-programming-forum/simple-ilogic-to-difference-between-titles/m-p/7417274#M97567</link>
    <description>&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Been struggling getting this to work:&amp;nbsp; we have two types of drawing.&amp;nbsp; one starts with L30, S89, C20 ETC for standard drawing parts and the other starts with 123-4567, 590-0101 for Purchase parts.&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am able to difference the two by using that firstletter as a string that RevCOde is = 65 (based on what I red from this site, ASCII character code for capital A)&amp;nbsp;(not sure if this is the best way but it works) , but there are also two types of drawing file that I want to do for description&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Title&amp;nbsp;1: without comma then description goes to description&lt;/P&gt;&lt;P&gt;Title 1: with comma, the second portion of comma goes to subject which works fine.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;everything works fine if I ran it with say L30-1234 TITLE 1, TITLE 2 but if doesn't work with L30-1234 TITLE 1 its still running the second command.&amp;nbsp; I believe the problem lies in the If, ENDif and AND but I cant quite pinpoint it.&amp;nbsp; Thanks for any help!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;If Firstletter &amp;lt; RevCode Then
iProperties.Value("Project", "Description") = description
docfile.ComponentDefinition.BOMStructure = 51973 'BOMStructureEnum.kPurchasedBOMStructure
iProperties.Value("Summary", "Subject") = "LIBRARY PART"
End If

'drawing items
If Firstletter &amp;gt;= RevCode Then
iProperties.Value("Project", "Description") = description
iProperties.Value("Summary", "Subject") = ""
End If&lt;BR /&gt;
If (Firstletter &amp;gt;= RevCode) And (FileName Like "*,*")
iProperties.Value("Project", "Description") = commadescription
iProperties.Value("Summary", "Subject") = Subject&lt;BR /&gt;End If&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 28 Sep 2017 15:14:55 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2017-09-28T15:14:55Z</dc:date>
    <item>
      <title>simple ilogic to difference between titles</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/simple-ilogic-to-difference-between-titles/m-p/7417274#M97567</link>
      <description>&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Been struggling getting this to work:&amp;nbsp; we have two types of drawing.&amp;nbsp; one starts with L30, S89, C20 ETC for standard drawing parts and the other starts with 123-4567, 590-0101 for Purchase parts.&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am able to difference the two by using that firstletter as a string that RevCOde is = 65 (based on what I red from this site, ASCII character code for capital A)&amp;nbsp;(not sure if this is the best way but it works) , but there are also two types of drawing file that I want to do for description&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Title&amp;nbsp;1: without comma then description goes to description&lt;/P&gt;&lt;P&gt;Title 1: with comma, the second portion of comma goes to subject which works fine.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;everything works fine if I ran it with say L30-1234 TITLE 1, TITLE 2 but if doesn't work with L30-1234 TITLE 1 its still running the second command.&amp;nbsp; I believe the problem lies in the If, ENDif and AND but I cant quite pinpoint it.&amp;nbsp; Thanks for any help!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;If Firstletter &amp;lt; RevCode Then
iProperties.Value("Project", "Description") = description
docfile.ComponentDefinition.BOMStructure = 51973 'BOMStructureEnum.kPurchasedBOMStructure
iProperties.Value("Summary", "Subject") = "LIBRARY PART"
End If

'drawing items
If Firstletter &amp;gt;= RevCode Then
iProperties.Value("Project", "Description") = description
iProperties.Value("Summary", "Subject") = ""
End If&lt;BR /&gt;
If (Firstletter &amp;gt;= RevCode) And (FileName Like "*,*")
iProperties.Value("Project", "Description") = commadescription
iProperties.Value("Summary", "Subject") = Subject&lt;BR /&gt;End If&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 28 Sep 2017 15:14:55 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/simple-ilogic-to-difference-between-titles/m-p/7417274#M97567</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-09-28T15:14:55Z</dc:date>
    </item>
    <item>
      <title>Re: simple ilogic to difference between titles</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/simple-ilogic-to-difference-between-titles/m-p/7417332#M97568</link>
      <description>&lt;P&gt;Would this work better?&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;PRE&gt;If Firstletter &amp;lt; RevCode Then
	iProperties.Value("Project", "Description") = description
	docfile.ComponentDefinition.BOMStructure = 51973 'BOMStructureEnum.kPurchasedBOMStructure
	iProperties.Value("Summary", "Subject") = "LIBRARY PART"
End If

'drawing items
If Firstletter &amp;gt;= RevCode Then
	If (FileName Like "*,*")
		iProperties.Value("Project", "Description") = commadescription
		iProperties.Value("Summary", "Subject") = Subject
	Else
		iProperties.Value("Project", "Description") = description
		iProperties.Value("Summary", "Subject") = ""
	End If
End If&lt;/PRE&gt;</description>
      <pubDate>Thu, 28 Sep 2017 15:30:25 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/simple-ilogic-to-difference-between-titles/m-p/7417332#M97568</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-09-28T15:30:25Z</dc:date>
    </item>
    <item>
      <title>Re: simple ilogic to difference between titles</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/simple-ilogic-to-difference-between-titles/m-p/7417360#M97569</link>
      <description>&lt;P&gt;Thank you so much for that fast reply,&amp;nbsp;I been scratching my head since last night. I didn't know how to put and if inside and if as you can tell.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 28 Sep 2017 15:37:11 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/simple-ilogic-to-difference-between-titles/m-p/7417360#M97569</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-09-28T15:37:11Z</dc:date>
    </item>
    <item>
      <title>Re: simple ilogic to difference between titles</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/simple-ilogic-to-difference-between-titles/m-p/7417377#M97570</link>
      <description>&lt;P&gt;Happy to help.&amp;nbsp; Glad it works.&amp;nbsp;&amp;nbsp;&lt;img id="smileyhappy" class="emoticon emoticon-smileyhappy" src="https://forums.autodesk.com/i/smilies/16x16_smiley-happy.png" alt="Smiley Happy" title="Smiley Happy" /&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 28 Sep 2017 15:38:59 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/simple-ilogic-to-difference-between-titles/m-p/7417377#M97570</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-09-28T15:38:59Z</dc:date>
    </item>
  </channel>
</rss>

