Back

If your email is not recognized and you believe it should be, please contact us.

Forum Replies Created

Viewing 15 posts - 76 through 90 (of 500 total)
  • Author
    Posts
  • in reply to: JS to delete old style and replacing it wih new one. #102498
    Masood Ahmad
    Participant

    To all the Geniuses rather Money-making guys,

    If I would have known JavaScript, then I wouldn’t have posted this request here. There’s no point suggesting this or that. Simply give the solution, or leave it as-is. No one is forcing you to respond.

    I remember, the times when people share their knowledge on the Forums including InDesignSecrets.com. But God knows from these money making guys have come together here. It seems that they are out of their job and trying to earn their livelihood in some or the other way :)

    @InDesignSecrets team, as I said earlier, please create a separate page for these money loving guys and let them earn bread & butter for the day.

    I’m desperate to learn JavaScript but not getting the starting point. I’m trying to catch someone who can teach me JS for InDesign. And I’m sure, one day I’ll learn JavaScript.

    Thanks a ton for all your responses!

    in reply to: Alternating Fills #102332
    Masood Ahmad
    Participant

    THANK YOU !!!!!!!!!!

    in reply to: JS to delete old style and replacing it wih new one. #102331
    Masood Ahmad
    Participant

    …nothing happened. As you said, some of the old styles are not available. It depends, how my source is formatted therefore, when I copy text from source to Template file, some unused styles don’t get copied to the Template. I think that’s the problem.

    Any suggestions would be much appreciated.

    in reply to: Script to select a file from specified folder? #102323
    Masood Ahmad
    Participant
    in reply to: Alternating Fills #102319
    Masood Ahmad
    Participant

    Thanks Colin for the inputs. I tried it but it seems there’s something missing.

    I think I have ordered the script correctly.
    The script just applies the myTableStyle but didn’t remove the overrides completely.

    Secondly, I need a script to do as:
    1/ Apply the myTableStyle style to the current table. By current table I mean the table with Cursor in it.
    2/ Format the table with Alternate Fills (the existing style do not have the Alternating Fills, I am not supposed to edit it).
    2.1/ First 1 Row : Color: None
    2.2/ Next 1 Row : Color: Black 20%

    And another script to:
    1/ Apply the myTableStyle style to the current table. By current table I mean the table with Cursor in it.
    2/ Format the table with Alternate Fills (the existing style do not have the Alternating Fills, I am not supposed to edit it).
    2.1/ First 1 Row : Color: None
    2.2/ Next 1 Row : Color: Black 20%
    3/ Convert the the first row to header of the current table.


    app.doScript(checkUserSelection, ScriptLanguage.JAVASCRIPT, undefined, UndoModes.ENTIRE_SCRIPT, "Process Table");

    function checkUserSelection ()
    {
    var a_table = checkWhichTable();
    if (a_table == null)
    {
    if (confirm("No table selected. Do you want to process all tables?") == false)
    return;
    allTables = app.activeDocument.stories.everyItem().tables.everyItem().getElements();
    for (aTable=0; aTable < allTables.length; aTable++) { processTable (allTables[aTable]); } } else { processTable (a_table); } }

    function processTable(table)
    {
    table.appliedTableStyle = "Table_Alternating-Fills";
    }

    function checkWhichTable()
    {
    // ensure the user made a selection
    if (app.selection.length != 1)
    return null;
    var currentTable = app.selection[0];
    if (currentTable.hasOwnProperty("baseline"))
    {
    currentTable = app.selection[0].parent;
    }
    while (currentTable instanceof Cell || currentTable instanceof Row || currentTable instanceof Column)
    currentTable = currentTable.parent;
    if (!(currentTable instanceof Table))
    {
    // No table selected
    return null;
    }
    return currentTable;
    }

    Masood Ahmad
    Participant

    I think it’s time to replace my specs :)

    Masood Ahmad
    Participant

    English please………

    This post is a duplicate entry here on InDesign Secrets. Obi-wan have already given a code to achieve this:

    Add paragraph style only to a paragraph with 2 lines or more.

    Masood Ahmad
    Participant

    I might be wrong, but I think ^\w+ means first word only. For two words the code could be something like this: ^\w+\w+.

    …… OR ……

    It will be much easier to use Nested Styles to apply the Bold character style to the first two words.

    Masood Ahmad
    Participant

    This is because, RGB has a bigger gamut than CMYK. So the CMYK and RGB will always differ especially with Red, Green and Blue shades. I hope the below given url will spread some light on it. You can search more about it on the net.

    https://www.hackworth.co/rgb-cmyk-spectrum-and-how-it-affects-printing-quality/
    https://www.centurypublishing.com/wp-content/uploads/2013/02/RGB-CMYK-Colors.pdf

    in reply to: PDF problems #100785
    Masood Ahmad
    Participant
    in reply to: No line breaks in TOC #100784
    Masood Ahmad
    Participant

    Indeed David! and that should be on top priority. Also program the forum to accept IDMLs and scripts.

    in reply to: Double text frame line #100782
    Masood Ahmad
    Participant

    …Or is it the Primary Text Frame on the Master page and Non-Primary (Normal) Text Frame on the Document page.

    Check this out !

    in reply to: CC2018 Copy paste bug #100781
    Masood Ahmad
    Participant

    That’s really not a good news in the new year.

    Happy New Year to all :)

    Masood Ahmad
    Participant

    Sheri, I would recommend to post some sample text here, so that the members can write a working code for you.

    in reply to: GREP for automatic Tabs? #100779
    Masood Ahmad
    Participant

    Hi Rheta, Why don’t you use the Next Style feature and create your paragraph styles with required indent and number-lists.

    However, as per your brief, here are my findings. Check and let me know if it works for you.

    GREP Find/Change:
    Step1:
    Find What: ^(\d)(\x{0020})(.+)
    Change to: $1$3

    Step2:
    GREP Find/Change:
    Find What: ^(\d.+\r)(.+)
    Change to: $1$2

Viewing 15 posts - 76 through 90 (of 500 total)