import the grep styles in more than a paragraph style

Hello

First of all, I must say that I have no experience in scripting. I do not create scripts, simply use the.

I have a script that imports a paragraph style grep styles to another (in the same document). Whenever I use it, I have to change the script, captures the source paragraph styles and target in this piece of code:

source = "origem";

target = "alvo";

What happens is that sometimes I need to do this lots of times (especially when the updating of old projects). Is it possible to import styles grep for more than a paragraph at the same time, listing multiple targets?

Thank you!

Sorry,

the variable 'source' changed during execution of the script old th. Don't have a close enough look...

Please replace:

function setGrepStyle(){
var target = arguments[0].toString();
error = "";
 basePStyle = theDoc.paragraphStyles.item(source);
if (!basePStyle.isValid) error = 'Source style does not exist';
 var target = theDoc.paragraphStyles.itemByName(target);
 if (!target.isValid) error += '\rTarget style does not exist';
 if (error != ""){alert (error); exit()}
  gs = basePStyle.nestedGrepStyles;
 for (i = 0; i < gs.length; i++)
        target.nestedGrepStyles.add (gs[i].properties);
        }

Work here, if this does not work on your machine, I'll write a new piece to add to the SNA nestedGrepStyles ship off the doScript is not really necessary...

Tags: InDesign

Similar Questions

  • Toshiba NB550-111 - no connection if the LAN cable is more than 2 metres

    Hello

    My newly purchased Toshiba NB550-111(Windows 7 Starter Service Pack 1) has problems with the LAN card.
    If the LAN cable is more than 2 meters, no relation to Allied Telesyn switch (no indicator led on the switch, 2 other desktop computers already connected). I tried not to connect in a different port (one used previously by one of desktop computers), no connection. I tried with 3 cables, still no results.

    Cables (cat5E, so important) have been tested OK before with a cable Tester, and I use both of them without any problem with another 2 desktop computers at home. I set another cable (5 m long, newly purchased) and tested for connectivity. It works very well with the other two offices, no results with the netbook. I tried with adapter it works, I disabled ' energy efficient ethernet "NIC, still no connection properties page. It only connects if the cable is less than 2 meters. I tried to connect the netbook directly to the DSL router, still no connection with a longer cable.

    The device is reported by windows as work very well, and the test Toshiba utility ends there is no problem. Windows I configured in the Control Panel, the Plan balanced for maximum performance in the power options, still no results.
    Any ideas, please?

    Now maybe stupid question but what is with WLAN? You don t want to use WLAN?

  • Loss of the GREP styles

    I had created a whole list of GREP-styles and suddenly I realize that they're all gone. Maybe it happened during the synchronization of the settings, either by installing Indesign 2014. Anyone know where the GREP styles created by the user are stored? I could try to get through my time Machine.

    GREP styles are the attributes at the level of the document that you should be able to load from an earlier document. Saved grep queries to search for? Change, however, are stored in the user preferences. You should find a folder named queries to search - replace in your profile or library in the same way where the preferences InDesign Defaults file is stored for each version. You can copy the entire folder to a new version, or only selected queries. For more information, see replace your preferences

  • I have a netbook 10 ", how do I get the newtab page displays more than 3 thumbnails?

    A few versions back (maybe mozilla 30?), the newtab page to view 9 thumbnails on my netbook 10 ". However, with recent updates, which was reduced to only 3. I know a netbook has a screen size much smaller than most of the computers and having more than 3 thumbnails (9 for example), could make for really small thumbnails on the newtab page, but I really didn't mind at the time where this was the case. If there is a way for the future updates of mozilla to always accommodate users of netbooks that would be much appreciated.

    Thank you.

    Hi, you need to zoom out to increase the number of thumbnails. Or you could try the New Tools tab add-on, which has a variety of customization possibilities. Hope that helps.

  • The calculator program working if the second number is more than 1 digit.

    I was setting up a calculator on labview, which works except for when I entered that a second number of the calculator does not have the correct value if the second number is more than 1 digit. I think it's down to the use of shift registers and result of the operation is forgotten when a key is pressed. I joined the program, if someone could confirm that this is the problem / suggest potential ways around this problem that would be a great help

    RavensFan wrote:

    Use default if Unwired.  Several of your tunnels are defined in this way, including the orange wire (double-precision) where you store your first operand.

    If you run an event where a wire is not connected through the tunnel will display by default (empty for string, double zero) and the shift register will then forget what he was originally in it.

    I think you meant not to use the default value if Unwired?  I think you have to tell him to use linked entry Tunnel--> Create and wire Unwired cases instead?

  • Why am getting started on the internet with the message saying that more than one computer using the same ip address

    am is started from the internet for 3 days pass with the message saying that more than one computer using the same ip address

    am is started from the internet for 3 days pass with the message saying that more than one computer using the same ip address

    Thatmessage normally means a another computer on your local network has the same IP as the computer you are on.

    You control your Local network?

  • I replaced a HP with an Epson Stylus all-in-one printer and cannot get the printer to print more than one page when printing from the computer.

    Original title: new printer

    I replaced a HP with an Epson Stylus all-in-one printer and cannot get the printer to print more than one page when printing from the computer.  The printer works fine when printing from a laptop or ipad!

    Start by going here--> http://www.epson.com/cgi-bin/Store/support/supDetail.jsp?UseCookie=yes&oid=232591&prodoid=63099059&infoType=Downloads&platform=nodetect

    If the web page has not correctly detected your operating system, select it by using the drop-down list.  Rather than using the "Combo package" recommended but huge, expand the "Drivers" section and download driver printer v2.32 to a location that you will remember later.

    • Click on the ORB start and go into devices and printers.
    • Select (click) the icon of your Epson printer.
    • Once you have selected the printer, a button labeled "Print server properties" will appear in the toolbar.  Click on this button.
    • Click the "Drivers" tab on the print server properties dialog box.
    • Select the Epson printer in the list of installed printer drivers, and then click 'remove '.
    • In the context menu, select "Remove driver and driver package" and click OK
    • Click Yes, and then delete
    • Once the removal process is complete, restart the computer (probably not really necessary, but can't hurt)
    • Install the driver and the software using the file that you downloaded earlier

    At this point, your printer should work fine.  However, if you want the ability to print by emailing a file to your printer, you may need to install both 'Remote Printer Driver v1.65' in the category 'Pilot' and "v1.30 utility Configuration of printer Epson Connect" in the "Utilities" category

  • No puedo scanear mi Patrick photosmart D110 at the pc, me dice more than hay escaneo error y abajo of escanee desde o consults PC manual

    No puedo escanear mi Patrick photosmart D110 documents has the PC me dice more than hay escaneo error

    y dice escanee PC o desde abajo consults el manual

    You should ask the HP support forum. You must also use English here.

    Usted debe hacer pregunta in el foro soporte of HP. Tambien tienes Québec use el Inglés!

    http://h30434.www3.HP.com/T5/printer-networking-and-wireless/HP-Photosmart-Printer-series-D110/TD-p/864951

  • I used the text tool function more than the reminder function, how do I get it back?

    I used the text tool function more than the reminder function, how do I get it back?

    Hi Slate7Berta,

    Please use Adobe acrobat reader DC Acrobat Reader DC Learn & support instead of touch Adobe, there seems to be a compatibility issue.

    Kind regards

    Nicos

  • Please God. turn off this product. Your help desk services do not work, cannot turn off. I use the retail SECTOR, xi of adobe acrobat. Connected to the internet. On more than 20 min. open for disable grayed out. Windows 7 pro x 64. This shit makes people

    Please God. turn off this product. Your help desk services do not work, cannot turn off. I use the retail SECTOR, xi of adobe acrobat. Connected to the internet. On more than 20 min. open for disable grayed out. Windows 7 pro x 64. This shit makes people use fraud. I just want what it OFF can be USED on another COMPUTER.

    can anyone in the customer support to disable this?

    Hello Terry,

    I checked the serial number and found that you have enough number of activations left to install on 2 computers.

    Please uninstall the software and activate it on another machine. In case of problems please let me know and I'll help you.

    My direct email: [email protected]

    Chat Support email:

    http://helpx.Adobe.com/x-productkb/global/Service1.html

    Kind regards

    Rave

  • How to use photoshop with the same account on more than one laptop?

    How to use photoshop with the same account on more than one laptop?

    a single user license entitles you to two facilities simultaneous/activations.  so, what's the problem?

  • How can I select only the records that have more than 1 attached userID?

    gurus of the afternoon...

    As queries title, I can't find examples by searching the forum then...

    Basically, I need to find all the web_user_ids who have more than 1 attribute_code of 'ICX_HR_PERSON_ID' in the table... I tried this but its is not as much as I think it should...

    SELECT web_user_id, attribute_code, number_value, COUNT (web_user_id)
    AS "Num of administrators."
    OF AK_WEB_USER_SEC_ATTR_VALUES
    -WHERE attribute_code = 'ICX_HR_PERSON_ID '.
    - AND web_user_id = '4123'
    Web_user_id GROUP, attribute_code, number_value
    SEEN (COUNT (web_user_id) > 1)
    ORDER BY web_user_id ASC;

    Val

    J

    Try:

    SELECT web_user_id, attribute_code, COUNT(web_user_id)
    AS "Num Of Administrators"
    FROM AK_WEB_USER_SEC_ATTR_VALUES
    WHERE attribute_code = 'ICX_HR_PERSON_ID'
    GROUP BY web_user_id, attribute_code
    HAVING (COUNT(web_user_id) > 1 )
    ORDER BY web_user_id ASC;
    

    Or, better, there is no need to extract the attribute_code:

    SELECT web_user_id, COUNT(web_user_id) AS "Num Of Administrators"
    FROM AK_WEB_USER_SEC_ATTR_VALUES
    WHERE attribute_code = 'ICX_HR_PERSON_ID'
    GROUP BY web_user_id
    HAVING (COUNT(web_user_id) > 1 );
    

    Max

    Published by: Massimo Ruocchio, November 12, 2009 16:28

  • How can I get rid of the coding that adds more than one page to print email?

    I now get more than just the sender, date, and issue information in emails. What information from "source"? Is it possible that I can print the email without printing the part "source"? I tried to copy what I would get if I printed the e-mail, but it's beyond my skill level. I hope that there is a switch somewhere that I can change to fix this problem.
    Thank you

    View | Headers | Normal

    I think that yours is set to "All".

  • Can I create multiple notebooks address with some of the same people in more than one case?

    I have several addresses for different accounts books. I can move people in an address book, however, which removes them from the first. I want to be able to 'copy' instead of 'move', while some are at more than one address book.

    Hold down the CTRL key while dragging from an address book to another.

  • Do you need to reset the PRAM or SMC more than once?

    I heard that the PRAM reset (more two carillons, like three..) or the SMC (do it twice, not one) more than once is sometimes necessary.

    What is your experience?

    If you have to do it more than once, it is because it is not done correctly the first time.

Maybe you are looking for