КОМЕНТАРІ •

  • @nadermounir8228
    @nadermounir8228 7 місяців тому +1

    Nice video looking forward to your next video 😊

  • @beverlynazareno2029
    @beverlynazareno2029 6 місяців тому

    Hi, how about if I want to clear values on colored cells? Not the whole row or column but just the highlighted ones. Or if I want to clear the cells based on the words on another cell? Thank you!

    • @ExcelMacroMania
      @ExcelMacroMania 6 місяців тому

      To clear values in colored cells you need to use the other method (Part2). See the video here: ua-cam.com/video/-OAfoPi-eX8/v-deo.htmlsi=cka8OnIL6kvOi2yz
      That other method loops through target cells and checks for any condition. For example, to clear values for a cell colored yellow you do something like this:
      For Each cel lIn targetRange
      If cell.Interior.Color = vbYellow Then cell.Value = ""
      Next cell
      To clear cells based on words from other cell you can to use Offset. For example, let's say you want to clear cells which have a cell in the same row and next column with the word "DONE":
      For Each cel lIn targetRange
      If cell.Offset(0,1) = "DONE" Then cell.Value = ""
      Next cell