cancel
Showing results for 
Search instead for 
Did you mean: 

Progress Bar in SAP MII

Former Member
0 Kudos

Hi all,        I want to create ProgressBar in SAP MII using servlets or without using applets for example, if the value is 25 the bar should be in red color and if the value is 50 the bar should be in blue color like that.        Should I need to use xsl? If so, How to create xsl with the corresponding xml.       Please anyone guide me to do the same.   Thanks in Advance

Accepted Solutions (0)

Answers (1)

Answers (1)

0 Kudos

Hi Merlin (or is it Michael),

Have you thought about using an SVG?  Take a look at inkscape.com for a freeware example and look at the MII help about their use.

Regards, Mike

Former Member
0 Kudos

Hi,  Thanks for the reply and I am new to this pls guide me. I have seen the project SAP MII Production Cockpit_System File, which is for MII 12.2 as in the following link  http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/60e23dd0-fb98-2e10-4d89-bcc4c534d...  and I want to have the same(ProgressBar) in MII 12.1 using servlets and loading xsl in the StyleSheet.Is it possible?  Thanks, Merlin

Former Member
0 Kudos

<p>Hi Michael,

I want to create same like in the following link http://scn.sap.com/thread/1583579, using  the servlet feature of MII and for me the default xsl is loading properly.

But if I give my created(maually) xsl, it is not loading properly showing error like "Unknown Display Type" and my style sheet version is 2.0. I need to show ProgressBar in web page.

My xml is,

  <?xml version="1.0" encoding="UTF-8" ?>

  <Rowsets DateCreated="2012-09-07T18:44:12" EndDate="2012-09-07T18:44:12" StartDate="2012-09-07T17:44:12" Version="12.1.8 Build(20)">

  <Rowset>

  <Columns>

  <Column Description="METRIC_NAME" MaxRange="1" MinRange="0" Name="METRIC_NAME" SQLDataType="12" SourceColumn="METRIC_NAME" />

  <Column Description="METRIC_VALUE" MaxRange="1" MinRange="0" Name="METRIC_VALUE" SQLDataType="4" SourceColumn="METRIC_VALUE" />

  <Column Description="METRIC_PREFIX" MaxRange="1" MinRange="0" Name="METRIC_PREFIX" SQLDataType="12" SourceColumn="METRIC_PREFIX" />

  <Column Description="METRIC_POSTFIX" MaxRange="1" MinRange="0" Name="METRIC_POSTFIX" SQLDataType="12" SourceColumn="METRIC_POSTFIX" />

  <Column Description="DISPLAY_TYPE" MaxRange="1" MinRange="0" Name="DISPLAY_TYPE" SQLDataType="12" SourceColumn="DISPLAY_TYPE" />

  </Columns>

  <Row>

  <METRIC_NAME>EffVsStd</METRIC_NAME>

  <METRIC_VALUE>93</METRIC_VALUE>

  <METRIC_PREFIX>10</METRIC_PREFIX>

  <METRIC_POSTFIX>20</METRIC_POSTFIX>

  <DISPLAY_TYPE>Text</DISPLAY_TYPE>

  </Row>

  <Row>

  <METRIC_NAME>OEE</METRIC_NAME>

  <METRIC_VALUE>64</METRIC_VALUE>

  <METRIC_PREFIX>50</METRIC_PREFIX>

  <METRIC_POSTFIX>55</METRIC_POSTFIX>

  <DISPLAY_TYPE>DisplayColor</DISPLAY_TYPE>

  </Row>

  <Row>

  <METRIC_NAME>QualityScore</METRIC_NAME>

  <METRIC_VALUE>70</METRIC_VALUE>

  <METRIC_PREFIX>23</METRIC_PREFIX>

  <METRIC_POSTFIX>48</METRIC_POSTFIX>

  <DISPLAY_TYPE>HeadLine</DISPLAY_TYPE>

  </Row>

  <Row>

  <METRIC_NAME>LineDetailsPage</METRIC_NAME>

  <METRIC_VALUE>55</METRIC_VALUE>

  <METRIC_PREFIX>56</METRIC_PREFIX>

  <METRIC_POSTFIX>78</METRIC_POSTFIX>

  <DISPLAY_TYPE>ProgressBar</DISPLAY_TYPE>

  </Row>

  </Rowset>

  </Rowsets>

I need to show the ProgressBar for the corresponding METRIC_VALUE in different colors, Pls help me to load my xsl and correct where I am wrong.And if you want any information pls let me know.

Regards,

Merlin</p>

0 Kudos

You can also hard code the xsl inside the XSL Transformation action block and see if there is a problem with it that way. 

I would also verify that the Prefix and Postfix column SQL Datatypes are correct (you have them as 12, but all the data would be 4). 

Good luck, Mike

Former Member
0 Kudos

Hi Michael,

I did but no use the same error prevails. I don know whether my xsl is correct.  My xsl is,

10 1

Pls check whether it is well formed and correct or am I missing something? Pls let me know.

Thanks,  Merlin

0 Kudos

Hi Merlin,

I am not an expert in xsl, so I don't think I can help you with this problem.  I have done some troubleshooting years ago and usually I would simply cut out parts of the code until I found the error source.  Other than that, I think some others might be able to help.

BTW, SCN really does not like the xsl posted into the comment window.  I think you will be much better off attaching it as a file or pasting it as a jpg.

Regards, Mike