1 Reply Latest reply on Jun 18, 2013 12:52 AM by Vamitul

    The difference between the "find and replace" from the menu and FindChangeByList.jsx

    vaconcord

      Hi! Please help me. Why it working from "find and replace" (grep), but dont working in FindChangeByList.jsx

       

       

      findreplace
      \r\d(.)\d\d0$0

       

       

      This procedure find enter,any digit, point, any digit, any digit and replace it all in 0, found.

       

      Example:

       

       

      beforeafter

      7.35

      0

      7.35

       

       

       

       

      But it not work in FindChangeByList.jsx  (file: FindChangeList.txt):

       

      grep{findWhat:"\r\d(.)\d\d"}{changeTo:"0$0"}{includeFootnotes:true, includeMasterPages:true, includeHiddenLayers:true, wholeWord:false}

       

       

       

      And it not work in this:

       

      var myDocument = app.documents.item(0);

      app.findGrepPreferences = NothingEnum.nothing;

      app.changeGrepPreferences = NothingEnum.nothing;

      app.findChangeGrepOptions.includeFootnotes = false;

      app.findChangeGrepOptions.includeHiddenLayers = false;

      app.findChangeGrepOptions.includeLockedLayersForFind = false;

      app.findChangeGrepOptions.includeLockedStoriesForFind = false;

      app.findChangeGrepOptions.includeMasterPages = false;

      app.findGrepPreferences.findWhat = "\r\d(.)\d\d";

      app.changeGrepPreferences.changeTo = "0$0";

      myDocument.changeGrep();

       

       

       

      Please help me understand. Thank!