I need a simple script (Break Link To Style)

Hi nice guys,
Can someone please provide a simple script that will break the links to styles in all the paragraphs in a document.
Thanks in advance
Maria*
*An non coder designer that simply is not capable of understanding javascript... (but I have tried!)

Hi Maria,
Jongware's post (http://forums.adobe.com/message/1890625#1890625) gave me a clue on how to do this.
Give this a try:
var i, j, myDoc = app.activeDocument,
          allStories = myDoc.stories,
          thisStory,
          thisPara;
for (i = 1; i < allStories.length; i++) {
          thisStory = allStories[i];
          for (j = thisStory.paragraphs.length - 1; j >= 0; j--) {
                    thisPara = thisStory.paragraphs[j];
                    thisPara.applyParagraphStyle(myDoc.paragraphStyles[0], false)
alert ("Job Done!");

Similar Messages

  • Break Link with Style

    Hello all,
    I need to break a link to an object style via script. I found this discussion:
    http://www.adobeforums.com/webx?128@@.59b4d4d7
    jxswm suggests the line founds[i].applyObjectStyle(dstStyle, false, false); but this is the same as clicking on "None" and not the same as calling "Break link to style". I.e. the formatiing is lost and replaced by [None].
    Has anyone found out how to break the link without the object changing its formatting?
    Thank you very much.

    Ah, not quite. "myObj.appliedObjectStyle = myTempStyle" removes overrides. But myObj.applyObjectStyle(mytempStyle, false false) does not, so this is easily fixed.
    For any lurkers or archive-diggers (like myself ;) ) my entire routine:
      var myMenuAction = app.menuActions.item("$ID/Copy");
      app.clearOverridesWhenApplyingStyle = false;
      if (app.selection.length > 0) {
        var noStyle = app.documents[0].objectStyles[0];
        for (var n=0; n < app.selection.length; n++) {
          var myObj= app.selection[n];
          var myStyle = myObj.appliedObjectStyle;
          if (myStyle != noStyle) {
            var myTempStyle = myStyle.duplicate();
            myObj.applyObjectStyle(myTempStyle, false, false);
            myTempStyle.remove();
      } else {
        beep();
        beep();
      app.copy();

  • Javascript: select all text, break link to style

    Hi
    I'd like to select all text in a Document (in different independent textboxes) and then break the link to it's style (in the program in the Flyout-menu of the paragraph styles)
    Is this function scriptable (javascript)?
    How do I select all the text?
    InDesign CS6, OS10.7.4
    Thanks

    In fact, I use the adobe findchangebylist to modified, I want to do a clear setting script, not only break link to style, but when i run the script that will get error, can u help me to fix it, my script is shown as below:
    main();
    function main(){
    var myObject;
    //var myCheckSelection = false;
    //Make certain that user interaction (display of dialogs, etc.) is turned on.
    app.scriptPreferences.userInteractionLevel = UserInteractionLevels.interactWithAll;
    if(app.documents.length > 0){
      if(app.selection.length > 0){
       switch(app.selection[0].constructor.name){
        case "InsertionPoint":
        case "Character":
        case "Word":
        case "TextStyleRange":
        case "Line":
        case "Paragraph":
        case "TextColumn":
        case "TextFrame":
        case "Text":
        case "Cell":
        case "Column":
        case "Row":
        case "Table":
         myDisplayDialog();
         break;
        default:
         //Something was selected, but it wasn't a text object, so search the document.
         //myFindChangeByList(app.documents.item(0));
                        //alert("Nothing Selected, Please Select Text Frame or Text.");
      else{
       //Nothing was selected, so simply search the document.
                //myFindChangeByList(app.documents.item(0));
                alert("Nothing Selected, Please Select Text Frame or Text.");
    else{
      alert("No documents are open. Please open a document and try again.");
    function myDisplayDialog(){
    var myObject;
    var myDialog = app.dialogs.add({name:"Joan New Clear Setting_v1.0"});
    with(myDialog.dialogColumns.add()){
       with(dialogRows.add()){
       with(dialogColumns.add()){
    staticTexts.add({staticLabel:"Search Range:"});
         var mySearchButtons = radiobuttonGroups.add();
         with(mySearchButtons){
         radiobuttonControls.add({staticLabel:"Current Document", checkedState:true});
                       if(app.selection[0].contents != ""){
        radiobuttonControls.add({staticLabel:"Selection", checkedState:true});
       with(dialogColumns.add()){
        with(borderPanels.add()){
         staticTexts.add({staticLabel:"Clear Setting:"});
         var myDateButtons = radiobuttonGroups.add();
         with(myDateButtons){
         radiobuttonControls.add({staticLabel:"English", checkedState:true});
         radiobuttonControls.add({staticLabel:"Chinese"});
    var myResult = myDialog.show();
    if(myResult == true){
      switch(mySearchButtons.selectedButton){
       case 0:
                     BreakLinktoStyleDocument();
                     TurnOffHyphenationDocument();
                     myObject = app.documents.item(0);
                     myCheckSelection = false;
        break;
                  case 1:
                     BreakLinktoStyleSelection();
                     TurnOffHyphenationSelection();
                     myObject = app.selection[0];
                     myCheckSelection = true;
        break;
      switch(myDateButtons.selectedButton){
      case 0:
      myFindChangeByList1(myObject, myCheckSelection);
      break;
      case 1:
      myFindChangeByList2(myObject, myCheckSelection);
      break;
      myDialog.destroy();
      //myFindChangeByList1(myObject);
    else{
      myDialog.destroy();
    function TurnOffHyphenationDocument() {
    app.activeDocument.stories.everyItem().texts.everyItem().hyphenation=false;
    myTables = app.activeDocument.stories.everyItem().tables.everyItem();
    myTables.cells.everyItem().paragraphs.everyItem().hyphenation=false;
    function TurnOffHyphenationSelection() {
    app.selection[0].texts[0].hyphenation=false;
    app.selection[0].cells.everyItem().texts[0].hyphenation=false;
    function BreakLinktoStyleDocument() {
    app.activeDocument.stories.everyItem().texts.everyItem().applyParagraphStyle(app.activeDoc ument.paragraphStyles.item(0), false);
    app.activeDocument.stories.everyItem().texts.everyItem().applyCharacterStyle(app.activeDoc ument.characterStyles.item(0), false);
    myTables = app.activeDocument.stories.everyItem().tables.everyItem();
    myTables.cells.everyItem().paragraphs.everyItem().applyParagraphStyle( app.activeDocument.paragraphStyles.item(0), false);
    myTables.cells.everyItem().paragraphs.everyItem().applyCharacterStyle( app.activeDocument.characterStyles.item(0), false);
    function BreakLinktoStyleSelection() {
    app.selection[0].texts.everyItem().applyParagraphStyle(app.activeDocument.paragraphStyles. item(0), false);
    app.selection[0].texts.everyItem().applyCharacterStyle(app.activeDocument.characterStyles. item(0), false);
    app.selection[0].cells.everyItem().texts[0].applyParagraphStyle(app.activeDocument.paragra phStyles.item(0), false);
    app.selection[0].cells.everyItem().texts[0].applyCharacterStyle(app.activeDocument.charact erStyles.item(0), false);
    function myFindChangeByList1(myObject, myCheckSelection){
    var myScriptFileName, myFindChangeFile, myFindChangeFileName, myScriptFile, myResult;
    var myFindChangeArray, myFindPreferences, myChangePreferences, myFindLimit;
    var myStartCharacter, myEndCharacter;
    var myFindChangeFile = myFindFile("/ScriptSupport/te.txt")
    if(myFindChangeFile != null){
            // Because the selection will change as we add/remove characters,
            // we'll need to reset the selection after each pass if we are
            // checking the selection. We'll get the index of the first character
            // in the selection (relative to the start of its parent story) and
            // the index of the last character in the selection (relative to the
            // *end* of the story, and we'll use them later in the script to
            // keep the ends of the selection in place.
      if(myCheckSelection == true){
       var myStart = myObject.characters.item(0).index;
       var myEnd = myObject.characters.item(-1).index;
       var myStory = myObject.parentStory;
       var myStoryEnd = myStory.characters.item(-1).index;
       myEnd = (myStoryEnd - myEnd)+1;
      myFindChangeFile = File(myFindChangeFile);
      var myResult = myFindChangeFile.open("r", undefined, undefined);
      if(myResult == true){
       //Loop through the find/change operations.
       do{
        myLine = myFindChangeFile.readln();
        //Ignore comment lines and blank lines.
        if((myLine.substring(0,4)!="text")||(myLine.substring(0,4)!="grep")||(myLine.substring(0, 5)!="glyph")){
         myFindChangeArray = myLine.split("\t");
         //The first field in the line is the findType string.
         myFindType = myFindChangeArray[0];
         //The second field in the line is the FindPreferences string.
         myFindPreferences = myFindChangeArray[1];
         //The second field in the line is the ChangePreferences string.
         myChangePreferences = myFindChangeArray[2];
         //The fourth field is the range--used only by text find/change.
         myFindChangeOptions = myFindChangeArray[3];
         switch(myFindType){
          case "text":
           myFindText(myObject, myFindPreferences, myChangePreferences, myFindChangeOptions);
           break;
          case "grep":
           myFindGrep(myObject, myFindPreferences, myChangePreferences, myFindChangeOptions);
           break;
          case "glyph":
           myFindGlyph(myObject, myFindPreferences, myChangePreferences, myFindChangeOptions);
           break;
         if(myCheckSelection == true){
          myStartCharacter = myStory.characters.item(myStart);
          myEndCharacter = myStory.characters.item(-myEnd);
          myObject = myStory.texts.itemByRange(myStartCharacter, myEndCharacter);
          app.select (myObject);
       } while(myFindChangeFile.eof == false);
       myFindChangeFile.close();
    alert("Done");
    function myFindText(myObject, myFindPreferences, myChangePreferences, myFindChangeOptions){
    //Reset the find/change preferences before each search.
    app.changeTextPreferences = NothingEnum.nothing;
    app.findTextPreferences = NothingEnum.nothing;
    app.findChangeTextOptions = NothingEnum.nothing;
    var myString = "app.findTextPreferences.properties = "+ myFindPreferences + ";";
    myString += "app.changeTextPreferences.properties = " + myChangePreferences + ";";
    myString += "app.findChangeTextOptions.properties = " + myFindChangeOptions + ";";
    app.doScript(myString, ScriptLanguage.javascript);
      myFoundItems = myObject.changeText();
    //Reset the find/change preferences after each search.
    app.changeTextPreferences = NothingEnum.nothing;
    app.findTextPreferences = NothingEnum.nothing;
    app.findChangeTextOptions = NothingEnum.nothing;
    function myFindGrep(myObject, myFindPreferences, myChangePreferences, myFindChangeOptions){
    //Reset the find/change grep preferences before each search.
    app.changeGrepPreferences = NothingEnum.nothing;
    app.findGrepPreferences = NothingEnum.nothing;
    app.findChangeGrepOptions = NothingEnum.nothing;
    var myString = "app.findGrepPreferences.properties = "+ myFindPreferences + ";";
    myString += "app.changeGrepPreferences.properties = " + myChangePreferences + ";";
    myString += "app.findChangeGrepOptions.properties = " + myFindChangeOptions + ";";
    app.doScript(myString, ScriptLanguage.javascript);
    var myFoundItems = myObject.changeGrep();
    //Reset the find/change grep preferences after each search.
    app.changeGrepPreferences = NothingEnum.nothing;
    app.findGrepPreferences = NothingEnum.nothing;
    app.findChangeGrepOptions = NothingEnum.nothing;
    function myFindGlyph(myObject, myFindPreferences, myChangePreferences, myFindChangeOptions){
    //Reset the find/change glyph preferences before each search.
    app.changeGlyphPreferences = NothingEnum.nothing;
    app.findGlyphPreferences = NothingEnum.nothing;
    app.findChangeGlyphOptions = NothingEnum.nothing;
    var myString = "app.findGlyphPreferences.properties = "+ myFindPreferences + ";";
    myString += "app.changeGlyphPreferences.properties = " + myChangePreferences + ";";
    myString += "app.findChangeGlyphOptions.properties = " + myFindChangeOptions + ";";
    app.doScript(myString, ScriptLanguage.javascript);
    var myFoundItems = myObject.changeGlyph();
    //Reset the find/change glyph preferences after each search.
    app.changeGlyphPreferences = NothingEnum.nothing;
    app.findGlyphPreferences = NothingEnum.nothing;
    app.findChangeGlyphOptions = NothingEnum.nothing;
    function myFindFile(myFilePath){
    var myScriptFile = myGetScriptPath();
    var myScriptFile = File(myScriptFile);
    var myScriptFolder = myScriptFile.path;
    myFilePath = myScriptFolder + myFilePath;
    if(File(myFilePath).exists == false){
      //Display a dialog.
      myFilePath = File.openDialog("Choose the file containing your find/change list");
    return myFilePath;
    function myGetScriptPath(){
    try{
      myFile = app.activeScript;
    catch(myError){
      myFile = myError.fileName;
    return myFile;
    and here is my text file, te.txt
    //001
    grep {findWhat:"."} {appliedLanguage: app.languagesWithVendors.item("English: USA"), kerningMethod: "無"} {includeFootnotes:true, includeMasterPages:true, includeHiddenLayers:true, includeLockedStoriesForFind:true, widthSensitive:true}
    //002
    grep {findWhat:"."} {kinsokuSet: "繁體中文避頭尾(s)"} {includeFootnotes:true, includeMasterPages:true, includeHiddenLayers:true, includeLockedStoriesForFind:true, widthSensitive:true}
    //003
    grep {findWhat:"."} {mojikumi: "nothing"} {includeFootnotes:true, includeMasterPages:true, includeHiddenLayers:true, includeLockedStoriesForFind:true, widthSensitive:true}
    //004
    grep {findWhat:"."} {ligatures:false} {includeFootnotes:true, includeMasterPages:true, includeHiddenLayers:true, includeLockedStoriesForFind:true, widthSensitive:true}
    //005
    grep {findWhat:"."} {gridAlignment: 1852796517} {includeFootnotes:true, includeMasterPages:true, includeHiddenLayers:true, includeLockedStoriesForFind:true, widthSensitive:true}
    //006
    grep {findWhat:"."} {leadingModel: 1248619858} {includeFootnotes:true, includeMasterPages:true, includeHiddenLayers:true, includeLockedStoriesForFind:true, widthSensitive:true}
    //007
    grep {findWhat:"."} {characterAlignment: 1247896172} {includeFootnotes:true, includeMasterPages:true, includeHiddenLayers:true, includeLockedStoriesForFind:true, widthSensitive:true}

  • [JS CS3] JS method for Object Styles Break Link to Style

    I have pages full of objects that are assigned the pesky "Basic Graphics Frame" object style. I need to do the equivalent of choosing "Break Link to Style" in the Object Styles panel on all the objects in many files.
    I haven't been able to find anything equivalent to the "Break Link to Style" functionality in looking through the Object Browser. Finding all objects with [Basic Graphics Frame] object style and applying an object style of [None] doesn't do the same result. Any ideas?

    hi:
    //FindObjectPreference
    myDoc = app.documents[0];
    app.findObjectPreferences = NothingEnum.nothing;
    app.changeObjectPreferences = NothingEnum.nothing;
    app.findChangeObjectOptions.properties =
      objectType: ObjectTypes.allFramesType, //graphicFramesType, textFramesType, unassignedFramesType
      includeFootnotes: true,
      includeHiddenLayers: true,
      includeLockedLayersForFind: true,
      includeLockedStoriesForFind: true,
      includeMasterPages:true
    //var graphicOStyleName = "[Normal Graphics Frame]";
    app.findObjectPreferences.appliedObjectStyles = myDoc.objectStyles.item(1);
    var dstStyle = myDoc.objectStyles.item(0);
    var founds = myDoc.findObject(0);
    var foundsLen = founds.length, i, found;
    for(i = 0; foundsLen > i ; i++){
      //app.select(founds[i]); alert(founds[i].appliedObjectStyle.name);
      founds[i].applyObjectStyle(dstStyle, false, false);
    <pre>
    jxswm

  • [JS][CS3] Break Link to Style

    Hello everyone.
    A while back ago I wrote a script to Brake Links to Paragraph Styles and Character Styles. That was easy since you can set to false the option "Clearing Overrides" when applying "No Paragraph Style" [0] or "None" [0]. But I cannot do such a thing with objectStyles "None" [0] even when setting the options to False. Every time the TextFrames get the ObjectStyle "None". And the GUI Palette is not showing a "+" as being modified.
    It does work when using "Break Link to Style" in the GUI.
    Any help would be appreciated...
    Alex.

    CTC Imaging wrote:
    Yes I did think of that solution, but I am trying to keep it clean. Especially if you are doing several document input as copy and pasting into a single document. Since I am trying to doing this automaticaly (The script is assigned to the COPY command through eventListener), if I choose ONE generic name to rename to, I will run into the same issue. Of course I could scan the DESTINATION document for that GENERIC names and add a prefix (counter) to the one I am going to rename in the ORIGINAL document. But It would not work if the DESTINATION document is not open YET! And I can't do it as PASTE because I have to copy with the correct naming FIRST.
    So the best option is to break the link. So how can I emulate "Break Link to Style" in the ObjectStyles menu from the GUI???
    Alex.
    Then you should add Date&Time at the end of name of current Char/Para/Object/Cell/TableStyle
    "MyHeaderStyle" -> "MyHeaderStyle(2010-01-04 16:12:35)"
    I don't think that you can do this TWICE in the same second in two different documents I've done something like that in one of my script and I've added 2 second extra loop to be sure that "random" name can't be duplicated
    robin
    www.adobescripts.co.uk

  • Need Random Image Script with Links

    I am needing a script for random images on my homepage. I
    need the image to have its own link depending on what image is
    displayed. I would like a php script (non database) if
    possible

    See comments on DW forum about random includes and this
    particular markup
    shown below.
    Murray --- ICQ 71997575
    Adobe Community Expert
    (If you *MUST* email me, don't LAUGH when you do so!)
    ==================
    http://www.dreamweavermx-templates.com
    - Template Triage!
    http://www.projectseven.com/go
    - DW FAQs, Tutorials & Resources
    http://www.dwfaq.com - DW FAQs,
    Tutorials & Resources
    http://www.macromedia.com/support/search/
    - Macromedia (MM) Technotes
    ==================
    "newhorizonhosting.com" <[email protected]>
    wrote in message
    news:e29on1$buf$[email protected]..
    >I figured it out by doing a random include
    >
    > <?
    > srand(time());
    > $random = (rand()%3);
    > print("$random");
    > require_once("./$random.php");
    > ?>

  • Need Random Image Script with Link

    I am needing a script for random images on my homepage. I
    need the image to have its own link depending on what image is
    displayed. I would like a php script (non database) if
    possible

    Not sure about the PHP but there are some good scrips on
    www.kaosweaver.com
    Paul Whitham
    Certified Dreamweaver MX2004 Professional
    Adobe Community Expert - Dreamweaver
    Valleybiz Internet Design
    www.valleybiz.net
    "newhorizonhosting.com" <[email protected]>
    wrote in message
    news:e28rpm$8is$[email protected]..
    >I am needing a script for random images on my homepage. I
    need the image to
    >have its own link depending on what image is displayed. I
    would like a php
    >script (non database) if possible

  • Oh Help please! Need a simple script

    I am trying to format text in a form field. I just want the text in the field to show up with the following properties when a user types in the form:
    Font: Verdana
    Size: 10pt
    Leading 12 pt (this is the important part!)
    Multiline but I don't want scroll bars.
    If some hero on here could supply me the script I input into the Custom Format script field I would be soooooo happy!
    Thanks!

    "You need to create a "rich text" field."
    That's great but how do I do that?
    What its AcroForms? Is that a separate plug-in or something? Sorry I'm asking some dumb questions but I really have no clue about this stuff. I'm using a Mac so I don't have LiveCycle
    Thanks

  • Break link to style

    I've just had a situation where the font in a masthead has changed.
    I am guessing that when the masthead was built, a default paragraph style was in place so that the masthead represented style overrides, and that somehow the overrides have been removed.
    To prevent it happening again I have broken the link to the style and I was expecting the type spec to then be bullet proof. But if I select it, although it no longer appears as a selected style in the paragraph panel, I am still able to use the panel to clear overrides, which returns the type to Times New Roman.
    I guess the TNR comes from the No Paragraph Style on which the original style was based. But having broken the link, I would not have expected this behaviour.
    Breaking the link to a style will obviously protect the type if the original style is edited, but shouldn't it also prevent regression to the base style?
    If not, I guess that means that the only way to make a piece of text unchangeable is to edit No Paragraph Style to exactly represent each piece of text before setting it.
    Any thoughts?
    k

    Thanks Dave.
    Deck = sub editor oldspeak for a line of headline.
    Maybe I'll go the styles folder route.
    I'm only assuming that the problem came from removing overrides. The magazine is set mostly in Myriad Pro, but the masthead is three decks of Helvetica Bold condensed at different sizes, leading and tracking to form a square. Some of the words are solid black, others are tinted.
    The magazine went to press with the Helvetica substituted by Myriad Pro Regular, but the size, leading and tracking seemed preserved so the headline looked right, just the wrong face. So perhaps removing overrides wasn't the culprit.
    This was on an inside page. The cover masthead, thank goodness, was as it should have been, which makes me rule out font substitution.
    The designer says she never touched the type at that point, so it's going to remain a mystery.
    I'm just trying to prevent accidents in the future.
    k

  • [JS] How to break link to paragraph style from script?

    I don't found the command break link to paragraph style from script.
    I want "unapply" the style from the text, but leave the formatting intact.
    Can help me?

    In the interface it's a separate command ("Break link to style"), but it seems in a script you have to use
    Paragraph.applyParagraphStyle (using:ParagraphStyle[, clearingOverrides:bool=true])
    You cannot use "null" or something similar for "ParagraphStyle", so I guess the idea is to use paragraph style #0 in your document (which is always "[No Paragraph Style]"). Be sure to set "clearing Overrides" to false, as it defaults to true.
    The following single line works on your current paragraph:
    app.activeDocument.selection[0].paragraphs[0].applyParagraphStyle (app.activeDocument.paragraphStyles[0], false);

  • Could someone please sketch out this simple script for me?

    Could someone please sketch out a simple java script for me. I will have a document with one background
    layer and a layer set (group) called "Analyze" that consists of 63 adjustment layers. The layer names in that "Analyze" group(folder) will be
    "01" ...through "63" with 01 on the bottom and 63 at the top. Initially, all of the adjustment layers will be invisible and  the
    group will be closed (not expanded). I need a simple  script that will check for the first invisible layer in that group
    and make it visible without selecting that layer nor expanding the group. The script has to check
    for the first invisible layer every time it runs because other actions may have turned off a layer in the set.
    The point of this is so I can hotkey flipping on the layers one at a time without expanding the set or
    changing focus off the  background. It seems it should be a simple loop, but I just can't wrap  my head
    around all the objects (e.g. Layer as opposed to Layers  and  Artlayer as opposed to Artlayers)
    and the constants constants.
    for (i = 63; i>0; i--){                 /* I have found layer indexes 0 are the topmost layer */
      if( layerset[i] == INVISIBLE){
               layerset[i] = VISIBLE;
                  break;
    Could someone please write me a simple script that would do this?
    Edit I found this and its very close to what I need:
    var doc = app.activeDocument;
    for(var i = 0 ; i < doc.layers.length;i++){
      doc.layers[i].visible = (i % 2 == 0);
    From here : Function to show/hide layer with Photoshop script (JSX) - Stack Overflow
    In my case I would rewrite it to this
    for(var i = 62; i >=0; i--){
         if(  !doc.layers[i].visible){
              doc.layers[i].visible =TRUE;
              break;
    My problem is I just need  to traverse the layers in my layerset "Analyze"
    How do  I reference just those? Is there a doc.layersets["Analyze"].layers[i].visible = TRUE?
    Message was edited by: Shawn Laughlin To add more information

    Well this works:
    var doc = app.activeDocument;
    var analyze = doc.layerSets.getByName("Analyze").layers
    for(var i = 62 ; i >= 0; i --){
        if (!analyze[i].visible){
            analyze[i].visible =1;
            break;
    Hard to believe TRUE is not a constant in java.

  • Break link to Character Style with JS (CS4ME)

    Hi,
    I'm wondering how to break a link to a character style in JS. By break
    link I mean removing the character style but preserving the formatting.
    Given a selected textStyleRange, say, in the UI there are two ways of
    doing this. One is to click "Break link to Style" in the flyout meny of
    the character style palette.
    The other is to right-click and select "Apply character style."
    It's a little unintuitive, because CLICKING on removes overrides,
    but right-clicking and selecting the menu option doesn't.
    So when I saw that, I said to myself aha! Probably:
    myText.appliedCharacterStyle = myCharStyle
    is equivalent to clicking on , while
    myText.applyCharacterStyle(myCharStyle)
    is equivalent to right-clicking on and choosing "Apply character
    style."
    But it isn't.
    They both apply None and remove all formatting.
    So, anyone know how to break a link to character style without removing
    formatting in JS?
    Thanks,
    Ariel

    Thanks Peter. That's interesting. After Shabbos I'll have to try figure
    out how to apply a character style without removing overrides as well.
    It may be a two-step procedure.
    Thanks,
    Ariel

  • Niceties of apply the [None] character style and its relation to Break link to Character Style (CS4 upwards)

    Hi,
    Am I the last to realise that, with text selected, clicking on is
    different from right-clicking on and selecting "Apply " in
    the character palette?
    Let me explain: Say you have some text selected. The text has a
    character style applied called "Superscript", whose only attribute is to
    apply superscript.
    Now, with that text selected, if you click on the result is that
    is applied and all formatting is lost.
    But, if you right-click on and choose "Apply " from the
    context menu, is applied but formatting is NOT list. Effectively
    this is the equivalent of choosing "Break link to style" in the flyout
    menu of the character palette.
    Curious to know if you've come across that that distinction before?
    Thanks,
    Ariel

    Sorry Peter. On behalf of the stupid Jive forums, I do apologize. Everywhere in my post where I wrote [None], it was jived up a little and changed to a link. (I've only got Internet access during breaks -- a self-imposed firewall that allows me to actually get some work done.)
    The post shoudl have read:
    Hi,
    Am I the last to realise that, with text selected, clicking on [None] is different from right-clicking on [None] and selecting "Apply [None]" in the character palette?
    Let me explain: Say you have some text selected. The text has a character style applied called "Superscript", whose only attribute is to apply superscript.
    Now, with that text selected, if you click on [None] the result is that [None] is applied and all formatting is lost.
    But, if you right-click on [None] and choose "Apply [None]" from the context menu, [None] is applied but formatting is NOT list. Effectively this is the equivalent of choosing "Break link to style" in the flyout menu of the character palette.
    Curious to know if you've come across that that distinction before?
    Thanks,
    Ariel

  • Simple script needed

    I work with InDesign doing text layout. I have used scripts, but have never had the time to learn JavaScript. I need what I assume is a fairly simple script. The script needs to do the following:
    1. Open a document.
    2. Ignore the missing font dialog box.
    3. Load all text style from another file, with the styles from that file overwriting the styles in the current document.
    4. Save the open document with the same name.
    The script needs to be able to batch process all of the document in a folder.
    If this is simple enough to do with several lines of code, I would appreciate it if someone could help me out. If it is more complex than that, I can possibly pay.

    Hi kwilson68, could you contact me by email? I might be able to help you out.

  • How to parse a text file and produce a dynamic shell script for linking?

    I have some mapping files, one example is like this one;
    $ cat CON_xfrm_contract_to_20080302.map
    (object mfile_c_type
    (path "file:OBSOLETE")
    (fs "file://amanos/s01/abinitio/data/prod/mfs/mfs_16way")
    (local_paths 16
      "file://amanos/s01/abinitio/data/prod/mfs/parts/mfs_16way_001/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat"
      "file://amanos/s01/abinitio/data/prod/mfs/parts/mfs_16way_002/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat"
      "file://amanos/s01/abinitio/data/prod/mfs/parts/mfs_16way_003/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat"
      "file://amanos/s01/abinitio/data/prod/mfs/parts/mfs_16way_004/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat"
      "file://amanos/s01/abinitio/data/prod/mfs/parts/mfs_16way_005/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat"
      "file://amanos/s01/abinitio/data/prod/mfs/parts/mfs_16way_006/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat"
      "file://amanos/s01/abinitio/data/prod/mfs/parts/mfs_16way_007/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat"
      "file://amanos/s01/abinitio/data/prod/mfs/parts/mfs_16way_008/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat"
      "file://amanos/s01/abinitio/data/prod/mfs/parts/mfs_16way_009/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat"
      "file://amanos/s01/abinitio/data/prod/mfs/parts/mfs_16way_010/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat"
      "file://amanos/s01/abinitio/data/prod/mfs/parts/mfs_16way_011/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat"
      "file://amanos/s01/abinitio/data/prod/mfs/parts/mfs_16way_012/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat"
      "file://amanos/s01/abinitio/data/prod/mfs/parts/mfs_16way_013/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat"
      "file://amanos/s01/abinitio/data/prod/mfs/parts/mfs_16way_014/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat"
      "file://amanos/s01/abinitio/data/prod/mfs/parts/mfs_16way_015/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat"
      "file://amanos/s01/abinitio/data/prod/mfs/parts/mfs_16way_016/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat"))In this file's content I have some exracted text files with same names under different folders;
    $ ls -lt /s01/abinitio/data/prod/mfs/parts/mfs_16way_*/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat   [
    -rw-rw-rw-   1 ab_live  abinitio 438652105 Mar  3 01:42 /s01/abinitio/data/prod/mfs/parts/mfs_16way_010/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    -rw-rw-rw-   1 ab_live  abinitio 438490410 Mar  3 01:42 /s01/abinitio/data/prod/mfs/parts/mfs_16way_016/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    -rw-rw-rw-   1 ab_live  abinitio 438219252 Mar  3 01:42 /s01/abinitio/data/prod/mfs/parts/mfs_16way_007/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    -rw-rw-rw-   1 ab_live  abinitio 438521432 Mar  3 01:42 /s01/abinitio/data/prod/mfs/parts/mfs_16way_014/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    -rw-rw-rw-   1 ab_live  abinitio 438488130 Mar  3 01:42 /s01/abinitio/data/prod/mfs/parts/mfs_16way_003/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    -rw-rw-rw-   1 ab_live  abinitio 438249547 Mar  3 01:42 /s01/abinitio/data/prod/mfs/parts/mfs_16way_002/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    -rw-rw-rw-   1 ab_live  abinitio 438312177 Mar  3 01:42 /s01/abinitio/data/prod/mfs/parts/mfs_16way_012/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    -rw-rw-rw-   1 ab_live  abinitio 439074566 Mar  3 01:42 /s01/abinitio/data/prod/mfs/parts/mfs_16way_015/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    -rw-rw-rw-   1 ab_live  abinitio 438722261 Mar  3 01:42 /s01/abinitio/data/prod/mfs/parts/mfs_16way_004/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    -rw-rw-rw-   1 ab_live  abinitio 438742477 Mar  3 01:42 /s01/abinitio/data/prod/mfs/parts/mfs_16way_001/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    -rw-rw-rw-   1 ab_live  abinitio 438517268 Mar  3 01:42 /s01/abinitio/data/prod/mfs/parts/mfs_16way_008/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    -rw-rw-rw-   1 ab_live  abinitio 438645835 Mar  3 01:42 /s01/abinitio/data/prod/mfs/parts/mfs_16way_011/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    -rw-rw-rw-   1 ab_live  abinitio 438334994 Mar  3 01:42 /s01/abinitio/data/prod/mfs/parts/mfs_16way_006/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    -rw-rw-rw-   1 ab_live  abinitio 438470743 Mar  3 01:42 /s01/abinitio/data/prod/mfs/parts/mfs_16way_005/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    -rw-rw-rw-   1 ab_live  abinitio 438095853 Mar  3 01:42 /s01/abinitio/data/prod/mfs/parts/mfs_16way_009/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    -rw-rw-rw-   1 ab_live  abinitio 438434204 Mar  3 01:42 /s01/abinitio/data/prod/mfs/parts/mfs_16way_013/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.datI need a shell script which will produce a shell script from the content of the mapping file so that I can be able to symbolicly link these files with different names and under the same folder, like;
    ln -s /s01/abinitio/data/prod/mfs/parts/mfs_16way_001/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat ./mfs_16way_001.CON_xfrm_contract_to_20080302.dat
    ln -s /s01/abinitio/data/prod/mfs/parts/mfs_16way_016/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat ./mfs_16way_016.CON_xfrm_contract_to_20080302.datI am a newbie for shell scripting, I tried several awk and sed operations but couldn't get close to this output :(
    If you guide me I will be so glad, thank you.
    ps: amanos is the name of this server.

    this is thepoint that I am stuck, I can not add the destination sym.link name to the end of each line;
    $ grep "  \"file://amanos" CON_xfrm_contract_to_20080302.map | cut -c17- | sed  's/"//;s/)//g' | sed 's/\/s01/ln -s \/s01/g'
    ln -s /s01/abinitio/data/prod/mfs/parts/mfs_16way_001/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    ln -s /s01/abinitio/data/prod/mfs/parts/mfs_16way_002/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    ln -s /s01/abinitio/data/prod/mfs/parts/mfs_16way_003/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    ln -s /s01/abinitio/data/prod/mfs/parts/mfs_16way_004/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    ln -s /s01/abinitio/data/prod/mfs/parts/mfs_16way_005/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    ln -s /s01/abinitio/data/prod/mfs/parts/mfs_16way_006/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    ln -s /s01/abinitio/data/prod/mfs/parts/mfs_16way_007/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    ln -s /s01/abinitio/data/prod/mfs/parts/mfs_16way_008/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    ln -s /s01/abinitio/data/prod/mfs/parts/mfs_16way_009/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    ln -s /s01/abinitio/data/prod/mfs/parts/mfs_16way_010/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    ln -s /s01/abinitio/data/prod/mfs/parts/mfs_16way_011/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    ln -s /s01/abinitio/data/prod/mfs/parts/mfs_16way_012/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    ln -s /s01/abinitio/data/prod/mfs/parts/mfs_16way_013/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    ln -s /s01/abinitio/data/prod/mfs/parts/mfs_16way_014/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    ln -s /s01/abinitio/data/prod/mfs/parts/mfs_16way_015/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    ln -s /s01/abinitio/data/prod/mfs/parts/mfs_16way_016/mfs_16way/Applications/RDS/CON_PUB/main/CON_xfrm_contract_to_20080302.dat
    $ /)//g' | sed 's/\/s01/ln -s \/s01/g' | awk -F\/ '{print $8"."$14}'                                                       <
    mfs_16way_001.CON_xfrm_contract_to_20080302.dat
    mfs_16way_002.CON_xfrm_contract_to_20080302.dat
    mfs_16way_003.CON_xfrm_contract_to_20080302.dat
    mfs_16way_004.CON_xfrm_contract_to_20080302.dat
    mfs_16way_005.CON_xfrm_contract_to_20080302.dat
    mfs_16way_006.CON_xfrm_contract_to_20080302.dat
    mfs_16way_007.CON_xfrm_contract_to_20080302.dat
    mfs_16way_008.CON_xfrm_contract_to_20080302.dat
    mfs_16way_009.CON_xfrm_contract_to_20080302.dat
    mfs_16way_010.CON_xfrm_contract_to_20080302.dat
    mfs_16way_011.CON_xfrm_contract_to_20080302.dat
    mfs_16way_012.CON_xfrm_contract_to_20080302.dat
    mfs_16way_013.CON_xfrm_contract_to_20080302.dat
    mfs_16way_014.CON_xfrm_contract_to_20080302.dat
    mfs_16way_015.CON_xfrm_contract_to_20080302.dat
    mfs_16way_016.CON_xfrm_contract_to_20080302.datMessage was edited by:
    antu
    Message was edited by:
    antu

Maybe you are looking for