1. Welcome to Chandoo.org Forums. Short message for you

    Hi Guest,

    Thanks for joining Chandoo.org forums. We are here to make you awesome in Excel. Before you post your first question, please read this short introduction guide. When posting or responding to questions please remember our values at Chandoo.org are: Humility, Passion, Fun, Awesomeness, Simplicity, Sharing Remember that we have people here for whom English is not there first language and we need to allow for this in our dealings.

  2. Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User


  3. When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

color code variance in sentence

Discussion in 'VBA Macros' started by shahzadb, Feb 9, 2019.

  1. shahzadb

    shahzadb New Member

    I want to color code values in a sentence. I want to know if it’s possible in excel via macro or formula. Or should I JavaScript to excel. I know bit of programming

    Here is an examples

    In Dec, our profit was -$20M below plan.

    In Dec, our sales was +10M above plan.

    I have then copy/paste into email. So I can’t type half of sentence in one cell and number value in cell with conditional formatting and third part of sentence in another cell because it would cause formatting
  2. Peter Bartholomew

    Peter Bartholomew Well-Known Member

    My feeling is that the boilerplate text should be in Word and the values in Excel. Then you could use VBA to transfer the values from named cells in Excel to the locations bookmarked in Word and only then apply formatting to the resulting Word objects. I am doubtful about the idea of using copy/paste rather than inserting values read and written to and from code variables.
  3. vletm

    vletm Excel Ninja


Share This Page