Excel - Cell background

Excel - Cell background

rohan_532rohan_532 Posts: 4Questions: 2Answers: 0

Hi need to loop over complete excel sheet rows and columns
the below code loops over the cells in column 'F' only can i loop over complete available columns in Excel sheet.

// Loop over the cells in column F
$('row c[r^="F"]', sheet).each( function () {
// Get the value and strip the non numeric characters
if ( $('is t', this).text().replace(/[^\d]/g, '') * 1 >= 500000 ) {
$(this).attr( 's', '20' );
}
});

Thanks .

This question has an accepted answers - jump to answer

Answers

  • F12MagicF12Magic Posts: 109Questions: 0Answers: 28
    edited July 2016 Answer ✓

    Hi @rohan_532,

    you clarified the question on my wall, and since this could be usefull to others, I'll answer this in the forum too.

    Problem:
    Check all cells in the sheet for a particular word, and color the background.

    Answer:
    See this JSFiddle: Working Example

    Another example searching 2 words:
    JSFiddle Example

  • rohan_532rohan_532 Posts: 4Questions: 2Answers: 0

    Hello F12Magic ,

    Thank you Very Much for your Help , This saved me :-)

    Thanks.

This discussion has been closed.