Skip to main content
Inspiring
February 18, 2022
Answered

EventListener for importing idms (place -> placegun)

  • February 18, 2022
  • 1 reply
  • 263 views

Hi, i tried to create a EventListener for getting data efter "Place..->file.idms" I have succeded to get triggered with theese before and after i Placegun is created, 

- beforeImport
afterImport
- beforePlace
 Now my problem, there is in the idms a part with images with LinkResourceURI, and i cant figure out how to get that data (i get images etc from snippet/placegun etc... but no data for Link part... ???
anyone ? suggestions ?
<Rectangle>
<Image>
<Link
LinkResourceURI="server.blabla.com/api/id=2321"
/>
</image>
</Rectangle>
    This topic has been closed for replies.
    Correct answer nilsh85014932

    Bah,

     

    <Image> <Link LinkResourceURI='http://blabla/blabla'> </Image>

     

    refers to an http address, and it is of course not approved by Indesign ...

     

    when testing on <Link LinkResourceURI='file://blabla/blabla'> </Image>

     

    i get excpected result....

     

    1 reply

    Inspiring
    February 24, 2022

    Tryig to add some more details about my problem...

    I need to get LinkResourceURI from images in placegun (after import of idms file)

     

    Closest event i found to use is afterImport, and then the the structure of data is

     

    PlaceGun -> Snippet -> Rectangle -> Graphic -> Image -> Link

     

    I have the image id via: placegun.snippets[0].rectangles[0].allGraphics[0].id (id 233)

    How can i get link attributes for the <Image> <Link LinkResourceURI='bla bla'> </Image> ?

     
    Any ideas ?

     

     

    nilsh85014932AuthorCorrect answer
    Inspiring
    February 24, 2022

    Bah,

     

    <Image> <Link LinkResourceURI='http://blabla/blabla'> </Image>

     

    refers to an http address, and it is of course not approved by Indesign ...

     

    when testing on <Link LinkResourceURI='file://blabla/blabla'> </Image>

     

    i get excpected result....