
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi All,
Been struggling getting this to work: we have two types of drawing. one starts with L30, S89, C20 ETC for standard drawing parts and the other starts with 123-4567, 590-0101 for Purchase parts.
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) (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
Title 1: without comma then description goes to description
Title 1: with comma, the second portion of comma goes to subject which works fine.
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. I believe the problem lies in the If, ENDif and AND but I cant quite pinpoint it. Thanks for any help!
If Firstletter < 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 >= RevCode Then iProperties.Value("Project", "Description") = description iProperties.Value("Summary", "Subject") = "" End If
If (Firstletter >= RevCode) And (FileName Like "*,*") iProperties.Value("Project", "Description") = commadescription iProperties.Value("Summary", "Subject") = Subject
End If
Solved! Go to Solution.