3 Replies Latest reply on Feb 9, 2016 12:28 PM by TᴀW

    How to find a specific text in a cell and remove it?


      I'm laying out a data intensive set of tables. Some have a "NULL" value which needs to be deleted along with the cell that contains it.

      Based on a similar script to delete rows containing text I've been trying the following to no avail:


      var doc = app.activeDocument, 

              _cells = doc.stories.everyItem().tables.everyItem().cells.everyItem().getElements(); 


                  if ( _cells.contents == "NULL" )  _cells.remove(); 




      Since I am a scripting novice; can you help me figure our what is wrong? Thanks!