<?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: Custom Job on lifecycle state change in Vault Customization Forum</title>
    <link>https://forums.autodesk.com/t5/vault-customization-forum/custom-job-on-lifecycle-state-change/m-p/8885026#M5022</link>
    <description>&lt;P&gt;Assuming that your target file is the primary linked component of your item you could get the file id in a single line if you got the item object instead of the file object within your job context:&lt;/P&gt;
&lt;PRE&gt;$primaryFile = $vault.ItemService.GetItemFileAssociationsByItemIds(@($item.Id), "Primary")&lt;/PRE&gt;
&lt;P&gt;The $primaryFile[0].CldFileId allows continuing in the given context of your job sample.&lt;/P&gt;
&lt;P&gt;Hope this helps.&lt;/P&gt;</description>
    <pubDate>Tue, 02 Jul 2019 11:51:08 GMT</pubDate>
    <dc:creator>Markus.Koechl</dc:creator>
    <dc:date>2019-07-02T11:51:08Z</dc:date>
    <item>
      <title>Custom Job on lifecycle state change</title>
      <link>https://forums.autodesk.com/t5/vault-customization-forum/custom-job-on-lifecycle-state-change/m-p/8884108#M5021</link>
      <description>&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I've downloaded coolOrange powerJob's for Vault and have begun experimenting with some of the sample codes (creating STEP, DXF etc).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I began by adding the Sample.CreateSTEP custom job type to the Review &amp;gt; Released lifecycle state change. During testing I could see the job getting added to the job server queue but it would fail to create a STEP file. I discovered that it would work perfectly if our lifecycle was assigned to files, but we use lifecycles on items instead!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can anyone point me in the right direction to get this working for lifecycle state changes on items? I want the job processor to create STEP files for all .ipt's that get released.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;</description>
      <pubDate>Mon, 01 Jul 2019 23:32:51 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vault-customization-forum/custom-job-on-lifecycle-state-change/m-p/8884108#M5021</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2019-07-01T23:32:51Z</dc:date>
    </item>
    <item>
      <title>Re: Custom Job on lifecycle state change</title>
      <link>https://forums.autodesk.com/t5/vault-customization-forum/custom-job-on-lifecycle-state-change/m-p/8885026#M5022</link>
      <description>&lt;P&gt;Assuming that your target file is the primary linked component of your item you could get the file id in a single line if you got the item object instead of the file object within your job context:&lt;/P&gt;
&lt;PRE&gt;$primaryFile = $vault.ItemService.GetItemFileAssociationsByItemIds(@($item.Id), "Primary")&lt;/PRE&gt;
&lt;P&gt;The $primaryFile[0].CldFileId allows continuing in the given context of your job sample.&lt;/P&gt;
&lt;P&gt;Hope this helps.&lt;/P&gt;</description>
      <pubDate>Tue, 02 Jul 2019 11:51:08 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vault-customization-forum/custom-job-on-lifecycle-state-change/m-p/8885026#M5022</guid>
      <dc:creator>Markus.Koechl</dc:creator>
      <dc:date>2019-07-02T11:51:08Z</dc:date>
    </item>
  </channel>
</rss>

