Remove all the missing links with frames

How can I make a script to remove all the missing links with frames in indesign?

var doc = app.activeDocument;
Links var = doc.links;

for (var i = links.length - 1; i > = 0; i--) {}
If (links [i] .status == LinkStatus.LINK_MISSING) {}
try {}
Links [i] .parent. Remove();
var image = link.parent;
var frame = image.parent;
Frame.Remove ();
counter ++;

}
{} catch (err)
$.writeln (i + "-" + err);
}
}
}

I have try this script, but still remain a framework, what is wrong with that?

It works for me:

var link, image, frame,
doc = app.activeDocument,
links = doc.links,
counter = 0;

for (var i = links.length-1; i >= 0; i--) {
    if (links[i].status == LinkStatus.LINK_MISSING) {
        try {
            link = links[i];
            image = link.parent;
            frame = image.parent;
            frame.remove();
            counter++;
        }
        catch (err) {
            $.writeln(i + " - " + err);
        }
    }
}

Tags: InDesign

Similar Questions

  • I am currently using Windows Vista. I face a problem that I can't remove all the files in the form of MPEG-4. Error with code 0x800704C8.

    I am currently using Windows vista. I face a problem that I can't remove all the files in the form of MPEG-4. And the error with code 0x800704C8. What should I do so that I can delete these files? Please kindly help me to solve this problem. Thank you.

    original title: Code 0x800704C8...

    Hello

    Did you change your computer?

    Method 1:

    Step 1:

    I suggest you follow the link and check.

    What are the permissions?

    http://Windows.Microsoft.com/en-us/Windows-Vista/what-are-permissions

    Step 2;

    Why can't I delete a file or a folder?

    http://Windows.Microsoft.com/en-us/Windows-Vista/why-cant-I-delete-a-file-or-folder

    Diagnose and repair Windows files and folders problems automatically

    http://support.Microsoft.com/mats/windows_file_and_folder_diag/

    Method 2:

    I suggest to download and install the Microsoft safety scanner and run the scan and check.

    http://www.Microsoft.com/security/scanner/en-us/default.aspx

    WARNING: There could be a loss of data while performing an analysis using the Microsoft safety scanner to eliminate viruses as appropriate

  • Remove the missing link of file-word (text) link

    I'm working on a former Indesign file that has the Word documents that are related to it. The links are missing, but the text takes the form of editable text so it has not lost.

    Can I copy and paste into a new text frame to solve the problem of the missing link.
    But it's a lot of work for a whole book. It would be perfect if I could break the link the Word of my frames of text file, but this option does not appear.

    I found 2-7 years old questions on the Adobe forums no useful response.

    Can someone help me with this?

    Thank you!

    "Ungroup" should be available in the context menu, if you click on the link in the links Panel.

    Since my German InDesign:

    Hope, that helps.

    Uwe

  • Can I remove all the links in a doc at a time?

    Servers us point were overwhelmed, so we always want to load pages, but for now, we want to remove all the links that point to these servers. However, we always want the text associated with the link to appear. In other words:

    Copy the following code:

    "< a href =" http://www.hollandamerica.com/dest/port.do?portCode=NPT & amp; dest = N "> Newport, Rhode Island < /a >"

    Will equal now to copy the following code:

    Newport, Rhode Island

    Is there a way to disable links or do a search/replace where it exits the tags, but not the text?

    I'm puzzled and I appreciate all help.

    Jon

    I never knew what were the "Regular Expressions". It will be exciting!

  • Windows 7, script to remove all the user accounts

    I'm on the technical support team.  On my desktop I have connection to more than 10 accounts per day to test and ensure that users are working.   Y at - it a script or a way to remove all the accounts?  Now, I need to right click on "computer" / Properties / advanced system settings / user profile settings / then remove them all one at a time and each of them take like 30-45 seconds.  I can remove the easy user profiles, but all accounts really slow things down.

    Hello

    Thanks for posting your query on the Microsoft Community.

    I would like to know some information.

    You are connected to a domain network?

    I suggest you re-post your query on the TechNet forums because we have experts working on this type of questions and for you help the better.

    Check out the link:

    https://social.technet.Microsoft.com/forums/Windows/en-us/home?category=w7itpro

    Hope this information helps. Please let us know if you need any other help with Windows in the future. We will be happy to help you.

  • Is there an easy way to find all the missing smart objects in your PS document?

    I have a file which is quite large with many layers and I can't seem to find the missing linked smart object. I usually just get Red? Select this option. But I looked and don't see that anywhere, but always get the message "could not document X.psd package, because it is missing a file linked smart object.»
    In InDesign at least we could see a list of all the links and just click it to redo the link. I was wondering if there was something escapes me? If this isn't the case, PLEASE add this feature. It's really one of the biggest mistakes when kind of forcing the users to use the cloud objects from the library.

    Hi toolsalesman,

    Refer to this article to the layers of filter based on the lack of linked smart objects: working with objects in dynamic in Photoshop

    Kind regards

    Claes

  • How to remove all the pictures imported from my I phone 6

    How to remove all the pictures imported from my I phone 6

    Imported from the place where?

    If they were imported from your computer, you remove the same way that you put on there: by syncing with iTunes. to remove them, you need to synchronize an empty folder, or simply turn off the Photo in the form of synchronization option summary pane when the iPhone is connected.

  • Remove all the patches and windows updates

    Hello

    How can I remove all the patches by using the Recovery Console - command prompt environment. Is it possible to remove all the patches. Where are all the patches and updates KB is stored in the Windows VISTA Business operating system. Help, please

    Thank you
    Concerning
    Anoop

    Hi Anoop,

    Thank you for writing to Microsoft Vista Community Forums.

    You can uninstall patches to a command using msiexec.exe and command line Options.

    For more information about the removal of patches of command prompt, access the link below: http://msdn.microsoft.com/en-us/library/aa372104 (VS.85) .aspx

    It will be useful.

    Thank you and best regards,

    Srinivas

    Microsoft Answers Support Engineer

    Visit our Microsoft answers feedback Forum and let us know what you think

  • Fill in the missing dates with level

    Think im a bad thing. I have some data that missing dates (days) and I want to just fill in the missing days with 0

    This sql is to look right or I'm doing something wrong:

    SELECT H.URL, H.V_DT, NVL CNT (P.CNT, 0))

    SELECT CAL. URL, CAL. MIN_DATE + LEVEL AS V_DT OF)

    SELECT the url, MIN (D) MIN_DATE, max (D) MAX_DATE

    USER_LOG_TMP2_VW where the url is not null and current_url (select distinct URL of USER_LOG_TMP_VW)

    GROUP BY URL

    After MAX (D) > MIN (D)) CAL

    CONNECT IN CAL. MIN_DATE + LEVEL < CAL. MAX_DATE

    -GROUP BY URL, CAL. MIN_DATE + level

    ): LEFT JOIN USER_LOG_TMP2_VW P ON P.URL = H.URL AND F.F. = H.V_DT

    There are only about 75 unique URL and when I run the present it works but I can't count because there are so many lines when it should be, perhaps a few thousand. the oldest date of min goes back only a few months.

    im getting strange results. As if I add a specific url like this (below)... it works perfectly for this url. But when I go out as above where it captures all urls... it gives me weird super results. As the dates twice for duplicate URLS.

    SELECT H.URL, H.V_DT, NVL CNT (P.CNT, 0))

    SELECT CAL. URL, CAL. MIN_DATE + LEVEL AS V_DT OF)

    SELECT the url, MIN (D) MIN_DATE, max (D) MAX_DATE

    OF USER_LOG_TMP2_VW, where url is not null and current_url to (select url from USER_LOG_TMP_VW where url = 'http://testing123.com/test/test"")

    GROUP BY URL

    After MAX (D) > MIN (D)) CAL

    CONNECT IN CAL. MIN_DATE + LEVEL < CAL. MAX_DATE

    -GROUP BY URL, CAL. MIN_DATE + level

    ): LEFT JOIN USER_LOG_TMP2_VW P ON P.URL = H.URL AND F.F. = H.V_DT

    I was not post create it for the views with her but I think that maybe im just something wrong with the level.

    I tried the group according to the level of url cal.min_date +, but for some reason it just keeps running and the query never ends.

    Hello

    Depending on your needs and your version, you may want a CONNECT BY clause like this:

    CONNECT BY LEVEL< max_date="" +="" 1="" -="">

    AND PRIOR url = url

    AND PRIOR SYS_GUID () IS NOT NULL

  • I have a new macbook pro and want to install CS3 on it. I followed all the download links. Found my serial number for my Adobe account and get up to date through the whole &amp; get this message ' put in place has encountered an error and cannot continue,

    I have a new macbook pro and want to install CS3 on it. I followed all the download links. Found my serial number for my Adobe account and get up to date through the whole & get this message ' put in place has encountered an error and cannot continue, contact adobe customer support for assistance ' all I want is for CS3 to install on my new computer so I can continue to work and do not have to spend hours working it help Please. CC is not an option, because I work in a country with no reliable unlimited internet access

    New computer means new problems of system operating with the OLD software means

    Fix possible Mac 10.10.4 (at least for Premiere Pro) https://forums.adobe.com/thread/1891705

    10.10 mac. ? sometimes has problems, often related to the 'default' permissions that need to be changed

    -solution https://forums.adobe.com/thread/1689788 of a person

  • How can I see all the missing files in the 12 elements?

    I have a very large catalog and there are now a few hundred missing files because of me, moving or deleting them out of the elements.

    Is there a way to display only the missing files in the elements in order to be able to work through them and decide to search manually or remove them from my catalog?

    Thanks for any help

    Lee

    If you are in items Organizer12, will find > all missing files

    It will show you all the missing files in your catalog.

    Thank you
    Blandine

  • Possible to remove all the traits?

    Hello community,

    I received a file of an architect, which basically means that they just exported their program of illustrator.

    Now, there are tons of shots unnecessary in this file, is there a way to keep only the filled boxes and remove all the traits?

    I can make them transparent, but the information for the traits will always be there (cmd + y). It is essential that they would disappear because the file will be sent to a plotter cutting and overall (even if it is set to transparent) lines will be cut off, which is what I don't want.

    I would be really happy if someone could help me with that. Otherwise I guess I'll just shift-click the last

    PS. I use Illustrator CS 5.5

    Kind regards

    PK

    In most Select > even take a look at the magic wand tool and its Panel.

  • How to make a list of all the missing files in a catalog in LR2?

    Is there an easy way to get a list of all the missing files for thumbnails in Lr2? I know that the symbol that appears in the upper right of any particular photo that does not contain the file, but how can I get a list of all these photos for a catalogue (or at least large chunks of a catalog).

    Thank you.

    You can click with the right button on a folder and choose synchronize - it has a button to display the missing files.

    John

  • How to remove all the photos from my iphone 5?

    How to remove all the photos from my iPhone 5?

    1. Open the Photos app.
    2. Click on the photo or video you want to delete.
    3. Type > delete the Photo.

    Delete several photos

    1. Open the Photos app and press Select.
    2. Click on each photo or video that you want to remove.
    3. Type > delete Photos.

    Delete photos on your iPhone, iPad and iPod touch - Apple Support

  • No backgrounds, text fields, text, borders areas. All-black text, all the blue links. No style sheet or put in the form of page layout

    No backgrounds, text fields, text, borders areas. All-black text, all the blue links. Any stylesheet or layout on all internet pages of setting shaped. Just randomly. I uninstalled, rebooted, re installed. Nothing solves this problem.

    This problem has been fixed by uninstalling Google Earth for some reason any it messes up Firefox when I install it.

Maybe you are looking for

  • Satellite A200 - what is the experience of the battery 9 cells?

    Hi im considering getting a battery 9 cells... Whats experince of peoples that they are much better? Where is a good place to go away and makes the quality varies a lot, or should I shop on price alone? How everyone takes care batterys there, you pul

  • Windows 7 problem on Portege M780 wireless

    We are having a problem with the network wireless on the M780. When you scan for available networks, he will find some, but not all local wireless networks.We have scanned using XP (on Dells and HPs) Vista (on Dells, Toshiba and HP) and Windows 7 (on

  • Unable to connect to Visual Studio 2010 with patch SP1 & GDR TSF.

    We're trying to access collection server TFS 2013 from Visual Studio 2010 (with patches SP1 & RDA recommended by MS supports), but get error below. \ First of all, we had problems with the application of SP1 & GDR patch, by MS supports, we repaired t

  • Error 0x8007000D install Windows Vista Service Pack 1

    original title: 0x8007000D When I update my service Pack 1 for vista I have error 0x8007000D

  • Mode of calendar MS unknown to me

    My MS Calendar application got a "mode", where most of the elements of the calendar has print very faintly, while one or more appointments are printed in black.  'Mode' that I am, and how do I get out of it?