A script to apply the style of cell to whole lines containing specific text

Hello

I use InDesign CC 2014

Does anyone know how apply a cellstyle based on the content of text found in a cell in javascript?

I need to find the document and change cell style in the entire line to 'cellStyle01' If the 'etc' text appears in the cell.

I found a similar script here to the forum which apply the table style, but do not know how to change it to apply the cell style!

var curDoc = app.activeDocument;
var allTables = curDoc.stories.everyItem().tables.everyItem();
  
app.findTextPreferences = app.changeTextPreferences = null;
app.findTextPreferences.findWhat = "someText";
var allFounds = allTables.findText();
app.findTextPreferences = app.changeTextPreferences = null;
  
for ( var i = 0; i < allFounds.length; i++ ) {
var curFound = allFounds[i];
if ( curFound.length == 1 ) {
var curFoundParent = curFound[0].parent;  
// curFoundParent.parent.appliedTableStyle = curDoc.tableStyles.itemByName( "tableStyle" );  
curFoundParent.parent.appliedCellStyle = curDoc.cellStyles.itemByName("cellStyle01");  
}
}

Thank you!

Hello

in this new case, you can't just change the last line, because yo I want to find not the entire table and lines and cells.

Try this modified version:

var curDoc = app.activeDocument;
var allTables = curDoc.stories.everyItem().tables.everyItem(); 

app.findTextPreferences = app.changeTextPreferences = null;
app.findTextPreferences.findWhat = "some Text";
var allFounds = allTables.findText();
app.findTextPreferences = app.changeTextPreferences = null;

for ( var i = 0; i < allFounds.length; i++ ) {
    var tableFound = allFounds[i];
    if ( tableFound.length > 0 ) {
        for ( var j = 0; j < tableFound.length; j++ ) {
            var curFound = tableFound[j];
            var cellsInRow = curFound.parent.parentRow.cells.everyItem();
            cellsInRow.appliedCellStyle = curDoc.cellStyles.itemByName( "cellStyle01" );
            cellsInRow.clearCellStyleOverrides( true );
        } // end for
    } // end if
} // end for

Tags: InDesign

Similar Questions

  • How to write the script to apply the character style?

    Hello

    I'm on a Macbook pro and without a numeric keypad, so I can't assign a shortcut to character styles. I heard a roundabout solution where you can assign a shortcut to a script that applies the character styles. Can anyone write this script?

    My character style is called "features"bold. "

    I am new to scripting, sorry if this is a stupid question.

    See you soon

    Hello

    1. save this code as a file inside your Script Panel folder .jsx

    2. apply a shortcut using the menu Edit: shortcuts...

    Option to choose:

    • suggest you choose an option 'background': 'Text', so you can use several shortcuts that are occupied in other contexts.
    #target indesign
    if (app.selection && app.selection[0].hasOwnProperty ("baselineShift") ) {
      var cName = "Features bold";
      var mCstyle = app.activeDocument.characterStyles.item(cName);
      if (mCstyle.isValid)
           app.selection[0].applyCharacterStyle(mCstyle);
      else
           alert ("CharStyle: " + cName + " not found");
      }
    else
      alert ("Some text supposed to be selected...");
    

    Jarek

  • Apply the style of paragraph 1 above and the style of paragraph 3 below all paragraphs containing only the italics?

    Hello

    I need a script that can find the paragraphs in italics only glyphs (maybe we can change all that pretty color) and apply the style of paragraph 1 above, the style of paragraph 3 below and this paragraph in italics to paragraph style 2

    Some paragraph of text (for the 1 paragraph style)

    some italic text (for paragraph style 2)

    little text (for the 3 paragraph style)

    After you run the script, I have something like this in 3 styles different points

    a text

    some italic text

    a text

    Lost link!

    /*

    Fixing paragraph style combinations

    Version: 1.2.B

    Script by Thomas Silkjaer

    http://indesigning.NET/

    Minor version b: Bruno Herfst

    + Add any style to replace paragraphs

    + Can cancel

    */

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

    Create a list of paragraph styles

    var list_of_paragraph_styles = [];

    var all_paragraph_styles = [];

    the_document.paragraphStyles.everyItem () .name;

    for (i = 0; i< the_document.paragraphstyles.length;="" i++)="">

    list_of_paragraph_styles.push (the_document.paragraphStyles [i]. (Name)

    all_paragraph_styles.push (the_document.paragraphStyles [i]);

    }

    for (i = 0; i< the_document.paragraphstylegroups.length;="" i++)="">

    for (b = 0; b< the_document.paragraphstylegroups[i].paragraphstyles.length;="" b++)="">

    list_of_paragraph_styles.push (the_document.paragraphStyleGroups [i] .name + ' /' + the_document. paragraphStyleGroups [i] .paragraphStyles [i] .name);

    all_paragraph_styles.push (the_document.paragraphStyleGroups [i] .paragraphStyles [i]);

    }

    }

    var list_of_replace_paragraph_styles = list_of_paragraph_styles.slice (0);

    list_of_replace_paragraph_styles.unshift ("[no paragraph style]" "");

    That the dialog box to select the paragraph styles

    var the_dialog = app.dialogs.add ({name: 'Paragraph style pairs Fix'});

    {with (the_dialog.dialogColumns.Add ())}

    {with (dialogRows.Add ())}

    staticTexts.add({staticLabel:"Find:"});)

    }

    {with (borderPanels.Add ())}

    var find_first_paragraph = dropdowns.add ({stringList:list_of_paragraph_styles, selectedIndex:0});})

    staticTexts.add ({staticLabel: "monitoring of"});

    var find_second_paragraph = dropdowns.add ({stringList:list_of_replace_paragraph_styles, selectedIndex:0});})

    }

    {with (dialogRows.Add ())}

    staticTexts.add({staticLabel:"Change:"});)

    }

    {with (borderPanels.Add ())}

    var change_first_paragraph = dropdowns.add ({stringList:list_of_paragraph_styles, selectedIndex:0});})

    staticTexts.add ({staticLabel: "monitoring of"});

    var change_second_paragraph = dropdowns.add ({stringList:list_of_paragraph_styles, selectedIndex:0});})

    }

    }

    {if (the_dialog. Show())}

    Define paragraph styles

    var find_first_paragraph = all_paragraph_styles [find_first_paragraph.selectedIndex];

    anyStyle var = false;

    If (find_second_paragraph. SelectedIndex == 0) {}

    anyStyle = true;

    }

    var find_second_paragraph = all_paragraph_styles [find_second_paragraph.selectedIndex - 1];

    var change_first_paragraph = all_paragraph_styles [change_first_paragraph.selectedIndex];

    var change_second_paragraph = all_paragraph_styles [change_second_paragraph.selectedIndex];

    Set preferences for grep to find to find all the points with the first selected paragraph style

    app.findChangeGrepOptions.includeFootnotes = false;

    app.findChangeGrepOptions.includeHiddenLayers = false;

    app.findChangeGrepOptions.includeLockedLayersForFind = false;

    app.findChangeGrepOptions.includeLockedStoriesForFind = false;

    app.findChangeGrepOptions.includeMasterPages = false;

    app.findGrepPreferences = NothingEnum.nothing;

    app.findGrepPreferences.appliedParagraphStyle = find_first_paragraph;

    app.findGrepPreferences.findWhat = ' $';

    Search current history

    var the_story = app.selection [0] .parentStory;

    var found_paragraphs = the_story.findGrep ();

    var change_first_list = [];

    var change_second_list = [];

    Browse the paragraphs and create a list of words and mark them as index words

    myCounter = 0;

    {}

    try {}

    Create an object to in paragraph reference and the following

    var first_paragraph is found_paragraphs [myCounter].paragraphs.firstItem ();.

    var next_paragraph = first_paragraph.paragraphs [-1] .insertionPoints [-1] .paragraphs [0];

    {if (anyStyle)}

    change_first_list.push (first_paragraph);

    change_second_list.push (next_paragraph);

    } else {}

    Check if the next paragraph is equal to the find_second_paragraph

    if(next_paragraph.appliedParagraphStyle == find_second_paragraph) {}

    change_first_list.push (first_paragraph);

    change_second_list.push (next_paragraph);

    }

    }

    } catch (err) {}

    myCounter ++;

    } While (myCounter<>

    Apply paragraph styles

    myCounter = 0;

    {}

    change_first_list [myCounter] .appliedParagraphStyle = change_first_paragraph;

    change_second_list [myCounter] .appliedParagraphStyle = change_second_paragraph;

    myCounter ++;

    } While (myCounter<>

    Alert ("fact pairs fixation!");

    }

  • InDesign CS3 - apply the style to the selection no longer works!

    Hello

    I have a little problem with InDesign CS3 and caraters style and paragraph style.

    style options in the options section and in the text, and in a style of object (even in GENERAL pannel), 'style to apply to the selection' appear in gray and I can not select, (or check), and is uncheked.

    In the room included an immage of a panel with the uncheched 'apply the style selection '.

    Please help me, what I have to do?

    I have try all thinghs but not reistalling jump is the last chance.

    Thank you for advice.

    ALE

    Your English is very good.

    The first thing I would try replacing the InDesign preferences. It seems to me that if you have repaired permissions of Mac files, but have does not replace the application preferences themselves. On Mac, the fast lane is close ID, then restart and IMMEDIATELY (almost instantly) press and hold the control + Cmd + Opt shift keys while the application starts. You should see a dialog box asking to confirm the replacement of preference. If you don't see the dialog box, you were not fast enough with the keyboard.

    You can also do a manual replacement. Look for the InDesign Defaults and InDesign SavedData files (these are probably hidden, but it will be in your user library) and just rename, move or delete. ID will create a new set at its launch. This has the advantage that you can recover your customizations by moving the prefs old return in the case where replacing them does not solve your problem.

    Things you lose are non-standard styles default and shades, which can be re-imported from a document that uses and document presets and a printer that can be saved from the dialog boxes "Set" before replacing your prefs and reloaded after same dialog boxes.

    Peter

    Edit: I see while I was busy typing Eugene was busy looking at the picture more closely I have and gave the real answer. Good info on the replacement of prefs, however, if you need it in the future.

  • Script to apply the master spread

    Hello

    This Script is for the page master opener co applying everywhere where CN is applied, when we run the script, it warns Sucess.But master spread is not applied. Please resolve.

    var mydoc=app.activeDocument; 
    var mypara = mydoc.stories.item(0).paragraphs.everyItem().getElements();
    for(i=0; i<mypara.length; i++){
        if (myPara[i].appliedParagraphStyle.name=="CN"){
               mypara[i].parentTextFrames[0].parent.appliedMaster = mydoc.masterSpreads.item("CO-Opener");
            }
        }
    alert("Master Page applied Sucessfully")
    

    Hi Math,

    I hope that your code is correct, but it seems [0] stories have no Styles "CN".

    Change the threshold:

    var = mydoc.stories.item mypara (0).paragraphs.everyItem () .getElements ();

    in

    var mypara = mydoc.stories.everyItem ().paragraphs.everyItem () .getElements ();

    Thanks Jongware and Green4ever...

    and also the use of the below url to get coding right for CS4 and CS5 and higher

    Apply the Master Page by using the paragraph Style

    var myDocument = app.activeDocument;
    var myParas = myDocument.stories.everyItem().paragraphs.everyItem().getElements();
    var myPage = myDocument.pages;
    for(i=0; i
    

    Concerning

    Siraj

  • Apply the style nested up to one of several characters

    I d-i-d try this old College, but maybe I don't know the right place or I am limited in nested Style in style GREP.

    I have a number any unpredictable predictable characters I want to apply a style CH "up to".

    Example 1: The Club of InDesign in the Future meeting, 15:30: here are some examples of text...  Here is some sample text...  Here are some examples of text--in this case, "up to" colon
    Example 2: The Club of InDesign in the Future meeting, 15:30 - here is an example of text...  Here is some sample text...  Here are some examples of text--in this case, "until" space hyphen

    Example 3: The Club of InDesign in the Future meeting, 15:30 - here is an example of text...  Here is some sample text...  Here are some examples of text--in this case, "until" space hyphen hyphen

    Example 4: The Club of InDesign in the Future meeting, 15:30, here is an example of text...  Here is some sample text...  Here is some example text--in this case, "up to" any character (comma) [of course, there is an argument in this one]

    There are 5-6. predictable samples.  But nested Styles stacked on each other tends to "BOLD" of the whole paragraph.  A js script would be more applicable here, or do you think the GREP style work?  I missed (even with my books on GREP) to any type of nail model.

    How do you tell the difference between the first and the second comma in the meeting, 15:30? They are all two followed by a space. PM maybe a clue? Then ^. +? pm\s [:-]-? might work.

    Peter

  • Apply the style at the top of the frame

    Hi all

    I put about 150 pages of continuous text in a Word doc.  The doc is constantly changed and whenever I set it to create a project, there is a different placement of words, which is fine.  The page size is also different in Word and InDesign, I might add.

    There is a B head paragraph style in InDesign that is allowed to occur anywhere.

    The problem is that when the head B occurs in the middle of a text frame, it must have a top rule.  But when it lands on top of a block of text, it cannot have a rule above.  Is there anyway to use GREP or script or something so that InDesign can identify when this style occurs in the upper part of the block of text, and have it use the style without the rule?

    I can't give the present advance in Word as the layout is totally different, once placed in InDesign.  And it's a bit of a pain for all find and adjust by hand whenever there are about 40 of them.

    Thank you very much!

    Sorry about that. This one should work:

    var myOriginalStyle = app.activeDocument.paragraphStyles.item("Body Head A")
    var myFinalStyle = app.activeDocument.paragraphStyles.item("Body Head A No Rule")
    var myStory = app.selection[0].parentStory;
    var myP = myStory.paragraphs.everyItem().getElements();
    for(var j = myP.length -1;j>=0;j--){
        var myTF = myP[j].parentTextFrames[0];
        if(myP[j].appliedParagraphStyle == myOriginalStyle && myTF.paragraphs[0] == myP[j])
        myP[j].appliedParagraphStyle = myFinalStyle
        }
    

    The script will change only the paragraph style, if the paragraph which has "Agency A" applied starts at the beginning of the text block (in other words, not if it has several lines and the first line starts inmiddle of the previous image).

  • Script to apply the IP address format

    Greetings,

    Acrobat Pro XI, in order to ensure that the user enters an IP address in the correct format, I have the following JavaScript called from tab Format text field properties by using a custom format script code.

    Validate the IPv4 address format

    var ipAdr = getField ("PHYSICAL IP ADDRESS");

    If (' event.value! = null & & event.value! = "") {}

    var re = / ^ \d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}$/;

    If (re.test (ipAdr.value) == false) {}

    App.Alert ("Please enter a valid IPv4 address");

    event.target.setFocus ();

    }

    }

    It seems to work, but I wonder:

    (1) it is ok to not have an else clause?

    (2) can the regular expression be improved?

    The regular expression seeks to apply the standard IPv4 dotted decimal notation that does not include the subnet mask.

    Thank you!

    There is no need for the command of setFocus. In addition, if you want to validate a value then you must use the Validate, not the event Format event.

    In the Validate event, you can also reject an incorrect value by setting event.rc false.

  • Apply the style of Pará to the xml element based on the type of master page?

    IM using a flow xml, im importing the xml to be used across different master page templates and I want to apply paragraph styles different items depending on what master page xml, they are on...

    So I have 3 put templates in place

    Type of page 1

    Type of page 2

    Type of page 3

    and 3 paragraph styles

    style 1

    style 2

    style 3

    I have the same xml structure deposited on each page...

    < Entry >

    < name > Page < / name >

    < / name >

    So, can I use javascript to apply the paragraph (style 1) style to the xml element (name) on any page that uses the master page (type of Page 1)

    Is this possible? whether and how this could be done?

    Thanks in advance

    Hello

    Try:

    #include '... / XML rules/glue code.jsx ";

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

    var myRuleSet = new Array (new applyParaStyle());

    {with (MyDoc)}

    var elements = xmlElements;

    __processRuleSet (Elements.Item (0), myRuleSet);

    }

    function applyParaStyle() {}

    myIdName = "Xp".

    This.XPath = "//restaurant_name";

    This.Apply = function (myElement, myRuleProcessor) {}

    {with (MyElement)}

    {Switch(insertionPoints[0].parentTextFrames[0].) ParentPage.appliedMaster.Name)}

    case "X-Master:

    App.Select (texts);

    App.Selection [0]. FillColor = myDoc.colors.item ("xxxx");

    break;

    case 'guide-Scotland:

    App.Select (texts);

    App.Selection [0]. FillColor = myDoc.colors.item ("scotland");

    by default:

    break;

    }

    }

    Returns true;

    }

    }

  • Apply the style to time creating AS3 components in CS3

    Hi all

    I try to use fl.controls.Button under Flash CS3 to replace some 'classic' resizable with a consistent look custom button symbols.  However, I want to apply an icon to the button when the creation of the provision of a specific frame on the timeline - but the only way I can see to set the icon on a button style is during execution with myButton.setStyle ().  No there is no way to customize the style properties of the AS3 components when creating the scene, such as the preview in the IDE vaguely match the end result?  The 'Properties' Inspector provides only inspectable properties 'stressed', 'label', 'labelPlacement', 'selected' and ' rocking' - how to assign style when creating information?

    see you soon,

    M.

    corrrect.

    you really shouldn't be using a component for what you want to use more than once and change each of them.  that goes against the advantage of using a component: it's a movieclip creation compiles only once.  There may be some built-in customizations (styles) but, it is intended to be used as-is.

    even if you have created your own custom button not compiled, you would face a similar situation: either, the code of the personalization features in your button (which wouldn't show before execution) or create several custom buttons.

  • Apply the style sheet to the entire project

    I inherited a project that has several style sheets (.css) and uses different style sheets for different subjects. I want to consolidate them and then apply a style sheet to the entire project. Does anyone know how to do?
    MAGNIN

    On the themes tab, select all of the themes, right click, select Properties. In the appearance of the theme properties dialog box tab, select the CSS you want.

    Good luck
    Leon

  • Apply the style to the submenu in Muse

    How can I request a style for the submenus when I create new elements in the planning window that I don't need to open the menu and click on each tab simple so I just newly created to change the style settings?

    This takes too long to change individual.

    I see what you mean. I just tried it myself. It seems to be good if you add a new top-level page, then he loses the formatting. Looks like a bug to me.

    Regarding the menu dead point goes, I think you'll need to use the item without hyperlink option. However, you can do this, even if the page is defined not to be exported, so he doesn't have to download null pages. He's not big, but it's better than nothing,

    David

  • Script to apply the cell style after paragraph research

    Hello

    can someone help my make a script to search for all occurrences of a paragraph format in the tables and then apply a cell style to a document the bounding cell.

    Thanks in advance.

    Peter

    BTW Mac InDesign CS 6

    Hello

    Use this:

    var mDoc = app.activeDocument,
    pST = mDoc.paragraphStyles.item("paraStyleName"),
    cST = mDoc.cellStyles.item("cellStyleName"),
    mFound, mParent, count;
    
    app.findTextPreferences = null;
    app.findTextPreferences.appliedParagraphStyle = pST;
    mFound = mDoc.findText();
    count = mFound.length;
    while (count--) {
         mParent = mFound[count].parent;
         if (mParent.constructor.name == "Cell")
              mParent.appliedCellStyle = cST;
         }
    
    app.findTextPreferences = null;
    

    change paraStyleName and cellStyleName

    Jarek

  • Apply the style of character for particular word only by script

    Hello

    I find the word especially in the indesign file. That must change italic character style applies.

    For example my topic levels "Ind - H1', 'Ind - H2', 'Ind - H3' have '(continued)' text, now my continuous text only get"Italic"character style for the declared position levels. Is it possible by script?

    by

    hasvi

    Maybe this can be written more short. I have two ideas:

    1.

    var curDoc = app.activeDocument;  
    
    app.findGrepPreferences = app.changeTextPreferences = null;     
    
    app.findGrepPreferences.findWhat = "see(?=:\\x20\\(continued\\))";
    var firstFound = curDoc.findGrep();
    app.findGrepPreferences.findWhat = "(?<=see:\\x20\\()continued";
    var secFound = curDoc.findGrep();
    var allFounds = firstFound.concat(secFound);
    
    for( var n = 0; n < allFounds.length; n++ ) {
        var curFound = allFounds[n];
        var curPara = curFound.paragraphs[0];
        if ( curPara.appliedParagraphStyle.name == "h1" || curPara.appliedParagraphStyle.name == "h2" ||curPara.appliedParagraphStyle.name == "h3" ) {
            curFound.appliedCharacterStyle = "italic";
        }
    } 
    
    app.findGrepPreferences.findWhat = "(?<=see):(?=\\x20\\(continued)";
    allFounds = curDoc.findGrep();
    
    app.findGrepPreferences = app.changeGrepPreferences = null;  
    
    for( var n = 0; n < allFounds.length; n++ ) {
        var curFound = allFounds[n];
        var curPara = curFound.paragraphs[0];
        if ( curPara.appliedParagraphStyle.name == "h1" || curPara.appliedParagraphStyle.name == "h2" ||curPara.appliedParagraphStyle.name == "h3" ) {
            curFound.appliedCharacterStyle = "bold";
        }
    }
    

    2.

    var curDoc = app.activeDocument;  
    
    app.findGrepPreferences = app.changeTextPreferences = null;     
    
    app.findGrepPreferences.findWhat = "see:\\x20\\(continued";
    var allFounds = curDoc.findGrep();
    
    for( var n = 0; n < allFounds.length; n++ ) {
        var curFound = allFounds[n];
        var curPara = curFound.paragraphs[0];
        if ( curPara.appliedParagraphStyle.name == "h1" || curPara.appliedParagraphStyle.name == "h2" ||curPara.appliedParagraphStyle.name == "h3" ) {
      app.findGrepPreferences.findWhat = "see|continued";
      app.changeGrepPreferences.appliedCharacterStyle = "italic";
      curFound.changeGrep();
      app.findGrepPreferences.findWhat = ":";
      app.changeGrepPreferences.appliedCharacterStyle = "bold";
      curFound.changeGrep();
        }
    } 
    
    app.findGrepPreferences = app.changeTextPreferences = null;
    
  • Apply the Style to the table using Extendscript CC cell text

    Hello

    I have the following code. I try to scan a document and a specific keyword research based on the regex. That part works. I then get the range of text for those keywords and the highlighted text. This method works. What does not work, it is when I try to do the same in the text that is in a table cell.

    #target framemaker
    
    var doc = app.ActiveDoc;
    var totalPgfs = 0;
    
    var pgf = doc.MainFlowInDoc.FirstTextFrameInFlow.FirstPgf;
    
    function do_table_work(pgf){
        var result = pgf.GetText(Constants.FTI_TblAnchor);
        var all_text = '';
        for (var i = 0; i < result.length; i += 1) {
            var t_object = result[i].obj;
            var t_cell = t_object.FirstRowInTbl.FirstCellInRow;
            while(t_cell.ObjectValid()){
                var cell_items = t_cell.GetText(Constants.FTI_String);
                var tr = new TextRange();
                 tr.beg.obj = tr.end.obj = pgf;
    
    
                 tr.beg.offset = 0; //this is built dynamically
                 tr.end.offset = 7; //this is built dynamically
    
                apply_char_format(text_range)
                t_cell = t_cell.NextCellInTbl;
            }
        }
    }
    
    function apply_char_format(text_range, name) {
        var color = doc.GetNamedColor(name);
        if (color.ObjectValid()) {
            var set_val = new TypedVal();
            set_val.valType = Constants.FT_Integer;
            set_val.ival = true;
            doc.SetTextVal(text_range, Constants.FP_UseBkColor, set_val);
    
    
            set_val.valType = Constants.FT_Id;
            set_val.obj = color;
            doc.SetTextVal(text_range, Constants.FP_BkColor, set_val);
        } else {
            alert('Color does not exist');
        }
    }
    
    while (pgf.ObjectValid()) {
        do_table_work(pgf);
        pgf = pgf.NextPgfInFlow;
    }
    

    The problem is that it is not highlighting the text in the table cell as I want it. If I process the document and use the following syntax:

    var result = pgf.GetText(Constants.FTI_String);
    

    It will highlight the text (with extra code to loop through these results).

    Any thoughts on what I'm missing?

    Hi Green,

    I don't have time to debug this script completely, but I see things that seem unusual.

    1. var result is TFP. GetText (Constants.FTI_TblAnchor);
    2. var all_text = ";
    3. for (var i = 0; i)< result.length;="" i="" +="1)">
    4. var t_object = .obj result [i];
    5. var t_cell is t_object. FirstRowInTbl.FirstCellInRow;
    6. While (t_cell. {ObjectValid()})
    7. var cell_items is t_cell. GetText (Constants.FTI_String);
    8. var b = new TextRange();
    9. TR. Beg.obj = tr.end.obj = bmp;

    GetText() is valid for a table cell, I don't know if that's what you want. I think I want to explore the individual paragraphs. I'm not quite clear on what this code does do exactly, but it seems that this would make it much easier to implement the text ranges. GetText() will cover all the paragraphs in a cell, if there are several.

    Added to this, your line "tr.beg.obj = tr.end.obj = bmp;" makes no sense to me, because you're coming back the paragraph which contained the anchor point of the table. In other words, you just leave the table entirely.

    So it's just a few riddles, but it seems more likely that you would something along these lines:

    1. var t_cell is t_object. FirstRowInTbl.FirstCellInRow;
    2. While (t_cell. {ObjectValid()})
    3. var cellPgf is t_cell. FirstPgf;
    4. var cell_items = cellPgf.GetText (Constants.FTI_String);
    5. var b = new TextRange();
    6. TR. Beg.obj = tr.end.obj = cellPgf;

    Hope this helps some.

    Russ

Maybe you are looking for

  • 4530 s: need help with missing drivers

    HelloI recently had to replace the HARD drive in my HP ProBook 4530 s (A6G60ES) I did a clean reinstall of Windows 7 Professional x 64. It works fine, but however, now I'm missing lots of drivers and Windows Update is not help. The page of the HP pro

  • Need drivers for my new HP Pavilion HPE ethernet

    Hello, I just bought a new HP Pavilion HPE desktop computer (3 days).  After that I got the first time I turned it on it only connected via the wireless network card.  I then did a clean install of windows 7 Ultimate edition (because I had it and it'

  • . Bar on the Load Simulator?

    Sorry for the newb-ish question. One of my friends gave me a file .bar for application, on which he works. I can't find a way to put the question on the Simulator. Flahs builder seems not to import, so I could not get my hands on the Simulator in thi

  • BlackBerry Smartphones MS Outlook do not update during the synchronization...

    I will say first... when I installed to the origin of the BB, I was using MS Outlook Express... and the phone seems to be sync well with this program... then I started using MS Outlook and adjusted the settings appropriate to indicate that my default

  • Load the party JavaScript libraries 3rd in footer to avoid conflicts

    I am a beginner with Muse. Trying to get my advantage javascript 3rd functions work, but we get jQuery UI conflicts, so we would like to load the library after the library of Muse.So, how can I load my 3rd party JavaScript libraries AFTER the jQuery