Change the fille colour of the current field using VBA RRS feed

  • Question

  • Hi!

    I have added a new column on the Task tab Gantt view, the column is text1 which I have renamed to Choice, I have used a custom field setting to have different lookup values.

    I want to have a particular fill color that I can change the field to using a button on the ribbon linked to the macro.  I recorded a macro & did this manually & changed the color to green.

    The macro selects the row & field (cell). I've tried to change this to be the current field (cell) so I can change the cell color of any cell I select but my vba is not good enough.

    Can anyone give me a simple set of VBA instructions that I can link to a ribbon button so that when I click on the button the color of the cell I clicked in will change.

    Many thanks for any help!


    Saturday, May 17, 2014 12:04 PM


  • Hi Ian,

    not sure, what version you are using. With simple line in macro, color of all selected cells is changed:

    Font32Ex CellColor:=65535 'just yellow

    Does this not work for you?

    To increase the value of this forum, please mark the replies that helped to solve your issue as answer. If you find answers to questions from other forum participants to be helpful, please mark them as helpful. Your participation will help others to find an appropriate solution faster. Thanks for your support!

    Saturday, May 17, 2014 12:57 PM

All replies