<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>Question Re: Color coding for column combination chart in Technology Q&amp;A</title>
    <link>https://community.sap.com/t5/technology-q-a/color-coding-for-column-combination-chart/qaa-p/361313#M23754</link>
    <description>&lt;P&gt;Hi Varun,&lt;/P&gt;&lt;P&gt;Sorry for the delayed reply i didn't get any notification on your comment.&lt;/P&gt;&lt;P&gt;The return function assigns value to the CSS class property dynamically.&lt;/P&gt;&lt;P&gt;It's like instead of giving a class name to the property, we can use this method to assign different classes in our css file based on our requirement. Like yours to change color at run time.&lt;/P&gt;&lt;P&gt;As in my scripting, based on month selected the css class will be assigned the chart. Here the return function sends string(class name) as value of the CSS class name property.&lt;/P&gt;&lt;P&gt;Let me know if more clarification needed.&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Poovarasan&lt;/P&gt;</description>
    <pubDate>Wed, 02 Nov 2016 15:24:04 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2016-11-02T15:24:04Z</dc:date>
    <item>
      <title>Color coding for column combination chart</title>
      <link>https://community.sap.com/t5/technology-q-a/color-coding-for-column-combination-chart/qaq-p/361309</link>
      <description>&lt;P&gt;HI experts,&lt;/P&gt;&lt;P&gt;Need help on color coding for Colum combination chart.&lt;/P&gt;&lt;P&gt;I have Jan to dec in X-axis. and i have yearmonth variable &lt;/P&gt;&lt;P&gt;whenever user selected  in variable color should change dynamically for example if he selected May 2015 .so till Apr 2015 bars should be black and remaining bars should be in blue&lt;/P&gt;&lt;P&gt;black bar-Actual&lt;/P&gt;&lt;P&gt;blue bar-Target&lt;/P&gt;&lt;P&gt;Please find the image&lt;/P&gt;&lt;P&gt;I Have tried by capturing variable and apply css.but no luck and i  reffered blogs as well but not full filled my requirement&lt;/P&gt;&lt;P&gt;any help would really appreciated.&lt;/P&gt;&lt;P&gt;&lt;A href="https://blogs.sap.com/2014/09/19/learn-about-arrays-in-design-studio-13/" target="test_blank"&gt;https://blogs.sap.com/2014/09/19/learn-about-arrays-in-design-studio-13/&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://archive.sap.com/discussions/thread/3759486" target="test_blank"&gt;https://archive.sap.com/discussions/thread/3759486&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://archive.sap.com/discussions/thread/3701365" target="test_blank"&gt;https://archive.sap.com/discussions/thread/3701365&lt;/A&gt;&lt;/P&gt;&lt;P&gt;var month = ["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];&lt;BR /&gt;&lt;BR /&gt; &lt;BR /&gt;&lt;BR /&gt;var a = PAPLS_OVERVIEW.getVariableValueText("PA_V_A_MM_YYYY");&lt;BR /&gt;&lt;BR /&gt; &lt;BR /&gt;&lt;BR /&gt;var  monthNum = Convert.stringToInt(a.substring(0,3));&lt;/P&gt;&lt;P&gt;CSS:&lt;/P&gt;&lt;P&gt;COL1 g.v-m-main g.v-m-plot g.v-column:nth-child(1) .v-datapoint.v-morphable-datapoint {fill: red!important; stroke: #E20015;}&lt;/P&gt;&lt;P&gt;&lt;IMG class="migrated-image" src="https://community.sap.com/legacyfs/online/storage/attachments/storage/7/attachments/3508-css-bars.png" /&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 26 Oct 2016 12:20:56 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/color-coding-for-column-combination-chart/qaq-p/361309</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2016-10-26T12:20:56Z</dc:date>
    </item>
    <item>
      <title>Re: Color coding for column combination chart</title>
      <link>https://community.sap.com/t5/technology-q-a/color-coding-for-column-combination-chart/qaa-p/361310#M23751</link>
      <description>&lt;P&gt;The closest, easiest way is to check page 73 of this document: &lt;A href="https://visualbi.com/wp-content/uploads/visualbi-extensions-for-sap-businessobjects-design-studio-vbx-user-guide.pdf" target="test_blank"&gt;https://visualbi.com/wp-content/uploads/visualbi-extensions-for-sap-businessobjects-design-studio-vbx-user-guide.pdf&lt;/A&gt; - not sure if it meets your requirement.&lt;/P&gt;</description>
      <pubDate>Wed, 26 Oct 2016 12:48:18 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/color-coding-for-column-combination-chart/qaa-p/361310#M23751</guid>
      <dc:creator>TammyPowlas</dc:creator>
      <dc:date>2016-10-26T12:48:18Z</dc:date>
    </item>
    <item>
      <title>Re: Color coding for column combination chart</title>
      <link>https://community.sap.com/t5/technology-q-a/color-coding-for-column-combination-chart/qaa-p/361311#M23752</link>
      <description>&lt;P&gt;Hi varun,&lt;/P&gt;&lt;P&gt;You cannot pass variables to css. But you can write logic in Formatter Function and use it to change the CSS class for your chart dynamically in Design studio versions 1.5 and above.&lt;/P&gt;&lt;P&gt;Let us consider your CSS file have classes like &lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;.month1 .(css class for bar coloring)&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;{Code to color first bar bar}&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;.month2 .(css class for bar coloring)&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;{Code to color bar}&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;.month2 .(css class for bar coloring)&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;{Code to color second bar bar}&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;note: classes are same as you used to color bars in your chart&lt;/P&gt;&lt;P&gt;you can write formatter function in data binding of CSS class as&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;var selected_month = "User selected month";&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;if (selected_month = 1)&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;{&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;return("month1");&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;}&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;if (selected_month = 2)&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;{&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;return("month2");&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;}&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;So your css class name will change according to the selection of month. For data cell binding you can use any data as we are not going to use in formatter function.&lt;/P&gt;&lt;P&gt;I think it will solve your problem.&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Poovarasan&lt;/P&gt;</description>
      <pubDate>Fri, 28 Oct 2016 08:35:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/color-coding-for-column-combination-chart/qaa-p/361311#M23752</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2016-10-28T08:35:48Z</dc:date>
    </item>
    <item>
      <title>Re: Color coding for column combination chart</title>
      <link>https://community.sap.com/t5/technology-q-a/color-coding-for-column-combination-chart/qaa-p/361312#M23753</link>
      <description>&lt;P&gt;HI Boopalan,&lt;/P&gt;&lt;P&gt;Thanks for your reply. May i know why used return here?&lt;/P&gt;&lt;P&gt;shall i use setcssclass or return.here?&lt;/P&gt;&lt;P&gt; i am just confused . i never explored on this .could you please explain in detail please?&lt;/P&gt;&lt;P&gt;and i Didnt find  formatter function any where in my chart.could you please guide me on this&lt;/P&gt;&lt;P&gt;My requirement&lt;/P&gt;&lt;P&gt;1. if user selected   May so till may color of bars should be back(actuals) and from june to december blue(target)&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Varun&lt;/P&gt;</description>
      <pubDate>Sun, 30 Oct 2016 13:55:46 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/color-coding-for-column-combination-chart/qaa-p/361312#M23753</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2016-10-30T13:55:46Z</dc:date>
    </item>
    <item>
      <title>Re: Color coding for column combination chart</title>
      <link>https://community.sap.com/t5/technology-q-a/color-coding-for-column-combination-chart/qaa-p/361313#M23754</link>
      <description>&lt;P&gt;Hi Varun,&lt;/P&gt;&lt;P&gt;Sorry for the delayed reply i didn't get any notification on your comment.&lt;/P&gt;&lt;P&gt;The return function assigns value to the CSS class property dynamically.&lt;/P&gt;&lt;P&gt;It's like instead of giving a class name to the property, we can use this method to assign different classes in our css file based on our requirement. Like yours to change color at run time.&lt;/P&gt;&lt;P&gt;As in my scripting, based on month selected the css class will be assigned the chart. Here the return function sends string(class name) as value of the CSS class name property.&lt;/P&gt;&lt;P&gt;Let me know if more clarification needed.&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Poovarasan&lt;/P&gt;</description>
      <pubDate>Wed, 02 Nov 2016 15:24:04 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/color-coding-for-column-combination-chart/qaa-p/361313#M23754</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2016-11-02T15:24:04Z</dc:date>
    </item>
  </channel>
</rss>

