ChageGrep Script works does not in IDCS3

I have a simple snippet that should do a GrepChange but it seems that he is unable to find the target text. Also, when I try to search through the user interface, it also fails to find the target text. Y at - he looking for a bug documented on grep in InDesign CS3?

Here's the script:

app.findChangeGrepOptions = NothingEnum.nothing;

app.findGrepPreferences = NothingEnum.nothing;

app.changeGrepPreferences = NothingEnum.nothing;

app.findGrepPreferences.findWhat = "^ $(Anthropology);

app.changeGrepPreferences.changeTo = "".concat("$1\\t2123")";

app.findChangeGrepOptions.includeFootnotes = false;

app.findChangeGrepOptions.includeHiddenLayers = false;

app.findChangeGrepOptions.includeMasterPages = false;

app.findChangeGrepOptions.includeLockedStoriesForFind = false;

app.findChangeGrepOptions.includeLockedLayersForFind = false;

var app.activeDocument.selection = results [0].parentStory.findGrep (false);

If (results.length == 0) {}

$.writeln ("ID not found.");

}

I have InDesign v 5.0.4.

The script works perfectly in CS4.

Thanks in advance,

-Jeff

You cannot assign app.findChangeGrepOptions nothing / null, you must set some or all of its properties to certain values, just as you do a few lines down in your script (like .includeFootnotes = true).

Peter

Tags: InDesign

Similar Questions

  • The CPL Script works does not on Cisco E Highway

    Hello

    I am trying to download the script to block all the RTC call hit on the highway E in order to avoid any misuse, however the script does not come into force.

    Attached the script and please let me know if something is missing.

    It is downloaded manually until highway E

    I check several post in CSC and it seems a necessity to download manually create rather than through GUI.

    For me the two does not work and call crosses ExpresswayC and CUCM.

    I want to block call to highway E itself, when not authenticated or unknown user sends the RTC call from 9 and +.

    Kind regards

    RACLOT

    You need to have something in the original section, leave empty will only match calls that actually have an empty source field.

    An alternative to using a source address which is supposed to be mapped is to specify the area that runs through the call, in this case because it is an external call entering the highway-E, the appeal will also come from the default Zone.

    Replace:

    unauthenticated-origin=""
    With:
    originating-zone="DefaultZone"
  • Ajax upload script works does not on a single server only?

    Someone has encountered a problem like this before?

    I use a "drag and drop" upload file image streams that works very well on square and 6 other remote hosts, I tried on but it does not work on the remote host, that I really need to work.

    I checked phpinfo and download file is about and what actually upload a picture if I use a direct access and select workflow that is a bit old hat.

    Was wondering if anyone had come across a situation like this before and what to look for in the phpInfo information. I put a call into hosting tomorrow because there must be a server configuration problem, but in the meantime, if anyone has any fire entry away.

    See you soon

    Operating system

    I'm struggling with a related problem right now.  A simple PHP script runs on the local server, but not the Server hosting - grrrrr...

    What PHP version on the server?

    Maybe a permissions issue?  Is the file receiving the image the value just read/write or read/write/execution?

    Nancy O.

  • power cli script works does not in 5.5-was prior work

    I am trying to perform actions on the virtual machines that reside in a csv file.    Here's what I have:

    to connect-viserver $vcenter

    foreach ()$_.name in ("Import-Csv " "$ENV: USERPROFILE\Desktop\vm_list.csv ' -UseCulture)) { }

    $VM = Get-VM $_. name

    Get-VM $VM | Where {$_. PowerState -eq "PoweredOn"} |

    Select Name, Host, NumCpu, MemoryMB,

    @{N='Cpu.UsageMhz.Average';} E={[Math]::Round((($_ | Get-Stat -Stat cpu.usagemhz.average -Start Get-Date(). () AddHours (-24) -IntervalMins 5 -MaxSamples (12) | Measure-object Value -Average). Average) , 2 )}},

    @{N='Mem.Usage.Average';} E={[Math]::Round((($_ | Get-Stat -Stat mem.usage.average -Start Get-Date(). () AddHours (-24) -IntervalMins 5 -MaxSamples (12) | Measure-object Value -Average). Average) , 2 )}} `

    | Export-Csv c:\Temp\stats.csv

    }

    NOTE - If I get rid of the thing whole 'foreach' script works fine Get - VM and down by removing the $VM variable)

    But I want to get the data of perf for VMs on my list, not only of each of them via the GET - VM against the whole vcEnter.

    Any ideas why it's a failure?   in 5.0, I ran a script that mobilized the "foreach" exactly as you see above and it worked great.  Now we are at 5.5 is more does not work.

    Output showing the errors that have baffled me:

    C:\Users\kwg\Desktop\test2.ps1:8 tank: 12

    + foreach ($_.name in (Import-Csv "$ENV:USERPROFILE\Desktop\vm_ip.csv")

    -UseCulture...

    +            ~

    Missing 'in' after variable in the foreach loop.

    C:\Users\kwg\Desktop\test2.ps1:8 tank: 83

    + ... "- UseCulture)) {}".

    +                    ~

    Unexpected token ')' in expression or statement.

    + CategoryInfo: ParserError: (:)) [], ParseException Exception)

    + FullyQualifiedErrorId: MissingInInForeach

    Not sure why you use the pipeline variable ($_____) in the foreach loop?

    There is no need to use a ForEach loop actually, you can pass several names for the Name parameter on the Get - VM cmdlet.

    And then you use the pipeline at its maximum.

    I would like

    to connect-viserver $vcenter

    Get-VM-name (Import-Csv "$ENV:USERPROFILE\Desktop\vm_list.csv" - UseCulture | % {$_.}) Name}) |

    Where {$_.} PowerState - eq "Receptor"} |

    Select Name, host, NumCpu, MemoryMB,

    @{N = "Cpu.UsageMhz.Average"; E = {[Math]: round ((($_ |))} Get-Stat - Stat cpu.usagemhz.average - Start (Get-Date). AddHours(-24)-IntervalMins 5 - MaxSamples (12) | Measure - Object - average value). Average), 2)}},

    @{N = "Mem.Usage.Average"; E = {[Math]: round ((($_ |))} Get-Stat - Stat mem.usage.average - Start (Get-Date). AddHours(-24)-IntervalMins 5 - MaxSamples (12) | Measure - Object - average value). Average), 2)}} |

    Export-Csv c:\Temp\stats.csv

  • missing fonts CS4 script works does not in CS5?

    Hi, my police lack script is working in CS3 and CS4, but does not not in CS4.

    I don't know why, any help please.

    Sam

    Object model has some changes in CS5.

    So use the code below in the upper part of your script.

    app.scriptPreferences.version = 6.0;

  • Show/hide an element with the click of a button - Script works does not in Firefox

    Hi all

    Basically, I'm looking for show/hide a DIV with the click of a button.

    The script works in IE but fail in FF.

    I am sure that I am the problem here.

    <script type="text/javascript">

    function toggle(box) {
         var el = document.getElementById('box');
         el.style.display = (el.style.display != 'none' ? 'none' : '' );
         
         
         value = document.getElementById('content').value;
         if(value=="Show Calendar"){
         document.getElementById('content').value="Hide Calendar";
         }
         else{
         document.getElementById('content').value="Show Calendar";     
    }
    }
    </script>


    <style type="text/css">
    #box{
         background-color: #C0C0C0;
         height: 100px;
         width: 100px;
    }
    </style>
    </head>

    <body>

    <div id="box">
    </div>

    <input id="content" value="Hide Calendar" type="button" onclick="toggle(box)" />
    </body>
    </html>

    WE

    He also worked if you had changed-

    
    

    on this subject.

    
    
  • Clean install of windows 7 and firefox 4, java script works does not on various websites

    A clean installation of windows 7 and firefox 4, there is a problem with java script, so far noticed on bbc iplayer (videos do not play) and ebay (pop-up menu options on pages like 'my ebay summary' just don't pop up), everything works fine in internet explore?
    tried safe mode, tried with and without flash and java runtime, everying of compensation has tried, tried to load the settings of internet explore...
    WON'T WORK!

    You have security software with enhanced settings that can block JavaScript in Firefox?

    Create a new profile as a test to see if your profile is the source of the problems.

    See:

    There may be extensions and plugins installed by default in a new profile, so check that in "tools > Modules > Extensions & Plugins" in case there are still problems.

    If this new profile works then you can transfer files from the old profile to the new profile (be careful not to copy corrupted files)

    See:

  • Why the Java plugin script works does not in PS?

    Have the demo version of PS CC 2015 d/load.

    When I try all the actions (for example to go to the bridge), I get say msg of error not complete command as long as PS could not found plugin java script.

    Am on Windows 7 64 bit

    Usage menu help > System Info... Look in the required section of the plug-in. Don't you see that listed ScriptingSupport in there?  If you do not have your Photoshop install did not work correctly.or you have some third party addon that requires him not not to load.  Try holding SHIFT as you start Photoshop and skip loading third-party addons...

  • InDesign scripting works does not in acrobat

    Hello Forum

    im running a script from indesign cs5 called swfpresenter but when I export the inderactive pdf file and open it in adobe acrobat pro, the animations do not work.

    What can be wrong?

    Thank you.

    Thanks for mentioning the steps that you follow. I tried a sample with InDesign files and it worked fine.

    What version of Acrobat?

    ~ Sandeep V.

  • Script works does not as expected

    Script should auto set annotations for me, it was taken directly from "VMWare vSphere PowerCLI référence" Chapter 5

    $VM = get - VM 'test '.

    $VM - get-VIEvent-entity Types information |

    Where-Object {$_.} GetType(). Name - match "VmBeingDeployedEvent". VmCreatedEvent | VmRegisteredEvent | VmClonedEvent"} |

    {ForEach-Object

    Set Annotation - entity $VM - CustomAttribute CreatedBy-value $Event.UserName

    Set Annotation - entity CustomAttribute - CreatedOn - $VM $Event.CreatedTime value

    }

    This is the error:

    Set Annotation: Impossible to validate the argument on the parameter 'value '. The argument is null or empt

    y. provide an argument that is not null or empty, and then try the command again.

    The Custom vars.ps1:8 char value: 15

    -Value + < < < < $Event.UserName

    + CategoryInfo: InvalidData: (:)) [game-Annotation], ParameterBindingValidation)

    Exception

    + FullyQualifiedErrorId: ParameterArgumentValidationError, VMware.VimAutomation.ViCore.

    Cmdlets.Commands.SetAnnotation

    Set Annotation: Impossible to validate the argument on the parameter 'value '. The argument is null or empt

    y. provide an argument that is not null or empty, and then try the command again.

    The Custom vars.ps1:11 char value: 15

    -Value + < < < < $Event.CreatedTime

    + CategoryInfo: InvalidData: (:)) [game-Annotation], ParameterBindingValidation)

    Exception

    + FullyQualifiedErrorId: ParameterArgumentValidationError, VMware.VimAutomation.ViCore.

    Cmdlets.Commands.SetAnnotation

    However a coupe version of the script:

    $VM = get - VM 'test '.

    $VM - get-VIEvent-entity Types information |

    Where-Object {$_.} GetType(). Name - match "VmBeingDeployedEvent". VmCreatedEvent | VmRegisteredEvent | VmClonedEvent"}

    Returns:

    Model: false

    Key: 1022221

    ChainId: 1022221

    Createduserid: 17/06/2011 10:52:15

    Username: EXAMPLE\Me

    Data Center: VMware.Vim.DatacenterEventArgument

    ComputeResource: VMware.Vim.ComputeResourceEventArgument

    Host: VMware.Vim.HostEventArgument

    VM: VMware.Vim.VmEventArgument

    Ds                   :

    Net                  :

    Dvs                  :

    FullFormattedMessage: Created the test of the virtual machine on vm6.example.com

    ChangeTag:

    DynamicType:

    DynamicProperty:

    I don't know if that makes a difference, but I am running 4.1u1 and 4.0 vSphere powerCLI

    Someone knows why?

    EDIT: running variable dir: dosent seem to show $Event as existing, $VM is here

    You need to replace $Event with $_ because you get the value of the line. Like this:

    $VM = Get-VM "test"
    Get-VIEvent -Entity $VM -Types Info |
      Where-Object { $_.Gettype().Name -match "VmBeingDeployedEvent|VmCreatedEvent|VmRegisteredEvent|VmClonedEvent"} |
      ForEach-Object {
        Set-Annotation -Entity $VM -CustomAttribute CreatedBy -Value $_.UserName
        Set-Annotation -Entity $VM -CustomAttribute CreatedOn -Value $_.CreatedTime
    }
    

    Best regards, Robert

  • with firefox 43 yahoo and yahoo mail doesn't work does not correctly

    With the help of win 7 and firefox 43.0.1, I have 4 computers and now all have problems with yahoo and yahoo mail doesn't work does not correctly. Loading sites, but most of the features are missing and clicking on what whether changes to the lists of text. I have disabled flash / anti-spam etc., cleared cookies and cache and even firefox loaded down once again and have upgraded, no help. I'm forced to use IE now.

    I tried Yahoo support, they said try Firefox... In any case, it's Firefox and I found a solution using the 'Refresh Firefox' button. Whatever the problem was fixed on two of my computers so far. Got to update my setting again but it's 10 m, compared to the 10 hours I spent trying all that is nothing.

    Thanks for the help!

  • Script error does not YouTube HTML5

    With the YouTube HTML5 (http://www.youtube.com/html5 ) mode is activated, any video that is played with the HTML5 player will give me a script error does not respond on "" Script: http://s.ytimg.com/yt/jsbin/html5player-vflGWJljH.js:58".

    Note that not all videos play on the HTML5 player. Try this video: http://www.youtube.com/watch?v=cdgQpa1pUUE

    Howard Forum Wiki gives me unresponsive script error as well. Go in http://www.howardforums.com/showwiki.php?title=Android+Wiki: on and click on the Discussion tab and I get an error of "Script: http://www.howardforums.com/clientscript/vault/reset.js?v=3014:285"script. "

    Google knows about the issue, and they should be updating the Web site later today.

  • Adobe flash player not working does not or does not appear as an application under Tools, options

    Adobe flash player not working does not or does not appear as an application under Tools, options

    If you can't Flash 11.3 to work and need to return to 11.2 Flash you can download Player Flash 11.2 through this direct link:

  • WIFI doesn't work does not correctly after driver update

    I have a DESIRE 4 laptop 1023tu with operating system Windows 8 PRO. My WIFI works does not properly after the update drievr.

    Problems...

    1. When you try to connect to a wifi hotspot the quick adapter turns off and allows the card instantly

    2. after connected, sometimes no internet access and the problem turns off only after reconnecting to the netwrok after setting off.

    If the update doesn't work not for you then do as I explained in my previous post and roll back to the previous driver. This philosophy can be applied to all updates.

    If there is no pressure or emerging reason to update to your PC or laptop works just great... do not update. (this is especially true when it comes to an update of the BIOS)

    For your question #2, the problem could be your wireless (modem, router or access point) which causes the connection dropped.

    Best regards
    ERICO

  • my microsoft work does not work error message that I need to reinstall, but I don't have a disck because it was already installed when I bought at walmart

    I bought my dell computer 2009 Wal-Mart, that he has is already set up with windows vista basic... and now my microsoft works does not work it says I have to reinstall.  However, he is not come with a disc. so, how can I do without having to buy a disc

    Go here: https://smartsource.dell.com

    This is where you go to download programs that have been installed on your computer that you do not have a CD for.

Maybe you are looking for

  • How to return to Yosemite fm El Cap?

    Have a Mac Pro Retina beginning 15 (256GB SSD) 8 GB Yosemite running. Read with alarm of some of the problems that others have some after upgrading to El Cap and I was wondering if it is easy to 'dismantling' in Yosemite (saved on Time Machine), if t

  • Cannot remove the document from the queue

    I deleted a print job, but I can't get out of the queue. I can't print anything now. How can I get rid of this document so I can use my printer?

  • CTXfiHlp MFC Application has stopped working

    A small window opens when I log on Windows 7. The title is "CTXfiHlp MFC Application has stopped working". I close the window, and everything seems to work perfectly. He did this a certain time and I decided to try to find a way to get rid of him. I

  • Malfunction of the point system

    A new problem with the game is that when I implemented negative points and the total score passes under 0, he pulls up to a large number, and I wish that the negative total to go score, is anyway to show?Here is my code:var: score: uint;function init

  • 65W ac adapter

    My Dv6525 use an AC adapter 65 w. is safe to use this as a spare part on my new Dv6-6071eo, who usually use a 120W. Of course, I understand that if it can be used and I use a lot of power on the Dv6 then the battery will discharge even if he was char