‎2013 Nov 03 8:10 PM
Dear All,
I am using the chart designer to generate the XML template for a columns chart. Then I am using the xml generated in my ABAP program. Every thing like background color, title etc are coming as per the requirement and defined in the XML template, except the color of the columns. The color of the columns are coming as the default color and not the ones I set in my designer. I am sure I am missing something, but not sure what
Here is my sample code for the creation of the series
f_series1 = f_ixml_data_doc->create_simple_element(
name = 'Series'
parent = f_chartdata ).
f_series1->set_attribute( name = 'customizing'
value = 'Series1' ).
f_series1->set_attribute( name = 'label' value = 'Open' ).
f_series2 = f_ixml_data_doc->create_simple_element(
name = 'Series'
parent = f_chartdata ).
f_series2->set_attribute( name = 'customizing'
value = 'Series2' ).
f_series2->set_attribute( name = 'label' value = 'Closed' ).
f_series3 = f_ixml_data_doc->create_simple_element(
name = 'Series'
parent = f_chartdata ).
f_series3->set_attribute( name = 'customizing'
value = 'Series3' ).
f_series3->set_attribute( name = 'label' value = 'Backlog' ).
I am not sure what I am missing
Thanks in advance for your help
Best Regards
Anirban
‎2013 Nov 04 7:10 AM
Hi,
After the f_series1 please add the below code
data : l_element type ref to if_ixml_element.
l_element = p_ixml_doc->create_simple_element(
name = 'Color' parent = f_series1 ).
l_element->if_ixml_node~set_value( 'RGB(69,193,208)' ).
l_element = p_ixml_doc->create_simple_element(
name = 'BorderColor' parent = f_series1 ).
l_element->if_ixml_node~set_value( 'RGB(69,193,208)' ).
change acordingly for the next two columns also
If any issues please Revert.
Thanks,
Pavan
‎2013 Nov 04 7:10 AM
Hi,
After the f_series1 please add the below code
data : l_element type ref to if_ixml_element.
l_element = p_ixml_doc->create_simple_element(
name = 'Color' parent = f_series1 ).
l_element->if_ixml_node~set_value( 'RGB(69,193,208)' ).
l_element = p_ixml_doc->create_simple_element(
name = 'BorderColor' parent = f_series1 ).
l_element->if_ixml_node~set_value( 'RGB(69,193,208)' ).
change acordingly for the next two columns also
If any issues please Revert.
Thanks,
Pavan
‎2013 Nov 04 8:24 AM
Hello Pavan,
I put the code as you mentioned, but it had no effects on the color of the columns (series). I checked OSS note 0001831400 and applied it, but seems the problem remains. Its really strange!!
Let me know if you know any other tricks
Thanks for your help
Best Regards
Anirban
‎2013 Nov 04 9:45 AM
Hi Anirban,
if possible give some screen shots of output and complete graph code.
Regards
Pavan
‎2013 Nov 04 11:14 AM
Hello Pavan,
Sorry for disturbing you but I finally found the problem. SAP Chart Designer is giving wrong template value for Plot area which was causing the XML transformation to fail.
Thanks for your help
Best Regards
Anirban