Highlighted

Function equivalent to "Break Link" in the Edit-->Links dialog box

Participant ,
Apr 21, 2017

Copy link to clipboard

Copied

Hello fellows,

I wonder if there is an API (in framescript/extendscript) for breaking a link to an imported inset file (Excel sheet, Visio, etc).

Thanks,

Roman

Adobe Community Professional
Correct answer by frameexpert | Adobe Community Professional

This won't work for OLE (linked) objects. The InsetFile property for these is always an empty string. These kinds of links are not exposed to the FDK, ExtendScript, or FrameScript. As far as I know, there is no way to break this kind of link programmatically.

TOPICS
Scripting

Views

252

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

Function equivalent to "Break Link" in the Edit-->Links dialog box

Participant ,
Apr 21, 2017

Copy link to clipboard

Copied

Hello fellows,

I wonder if there is an API (in framescript/extendscript) for breaking a link to an imported inset file (Excel sheet, Visio, etc).

Thanks,

Roman

Adobe Community Professional
Correct answer by frameexpert | Adobe Community Professional

This won't work for OLE (linked) objects. The InsetFile property for these is always an empty string. These kinds of links are not exposed to the FDK, ExtendScript, or FrameScript. As far as I know, there is no way to break this kind of link programmatically.

TOPICS
Scripting

Views

253

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Apr 21, 2017 0
Advocate ,
Apr 21, 2017

Copy link to clipboard

Copied

Hi Roman,

With a simple script you can find the inset to be unlinked and set its InsetFile property to an empty string. That should do the trick, I think.

Ciao

Jang

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Apr 21, 2017 0
Participant ,
Apr 23, 2017

Copy link to clipboard

Copied

Hi Jang,

I appreciate your input! No wonder I didn't find any function related to that. Following your suggestion, I came up with the following code.

The problem is that for a reason that is unclear to me, I can't retrieve the InsetFile path using alert() and can't make it null. The alert dialog box that pops up contains no value. What am I missing?  

var doc= app.ActiveDoc; 

DisconnectGraphics(doc); 

 

function DisconnectGraphics(doc) 

          

   var graph = doc.FirstGraphicInDoc; 

       while (graph.ObjectValid()) { 

       

            if ( graph.type == Constants.FO_Inset ) { 

               alert(graph.InsetFile);

               graph.InsetFile = "";

                                                              

               } 

         graph = graph.NextGraphicInDoc;   

  } 

    

Thanks!

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Apr 23, 2017 0
Adobe Community Professional ,
Apr 23, 2017

Copy link to clipboard

Copied

This won't work for OLE (linked) objects. The InsetFile property for these is always an empty string. These kinds of links are not exposed to the FDK, ExtendScript, or FrameScript. As far as I know, there is no way to break this kind of link programmatically.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Apr 23, 2017 0
rombanks LATEST
Participant ,
Apr 23, 2017

Copy link to clipboard

Copied

Hi Rick,

Thank you for your response!

I was afraid that Adobe didn't cover the OLE2 use case...

I'll check if this can be done with AutoIt.

Best Wishes,

Roman

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Apr 23, 2017 0