0

다음과 같이 두 가지 범주와 하나의 계열로 막대 차트를 만들었습니다.MSCRM 2015 : 막대 차트의 범례 이름 바꾸기

차트 조건 enter image description here

요구 사항은 지속적인 및 취소를 열고 실격 범례 이름을 변경하는 것입니다 enter image description here

차트. 범례 이름은 두 번째 범주 (상태)뿐입니다. 코드를 살펴 보았지만 범례 이름을 추가 할 위치를 파악할 수 없었습니다. 가능한 경우 해결책을 제안하십시오. 아래는 내가 참고로 제공 한 코드입니다.

<visualization> 
    <visualizationid>{C9D241BD-29E6-E711-80DC-00505695684B}</visualizationid> 
    <name>Assessment Revenue by Year</name> 
    <primaryentitytypecode>lead</primaryentitytypecode> 
    <datadescription> 
    <datadefinition> 
     <fetchcollection> 
     <fetch mapping="logical" aggregate="true"> 
      <entity name="lead"> 
      <attribute name="new_assessmentyear" groupby="true" alias="_CRMAutoGen_groupby_column_Num_0" /> 
      <attribute name="pjdm_income" aggregate="sum" alias="_CRMAutoGen_aggregate_column_Num_0" /> 
      <attribute name="statecode" groupby="true" alias="_CRMAutoGen_groupby_column_Num_13" /> 
      </entity> 
     </fetch> 
     </fetchcollection> 
     <categorycollection> 
     <category alias="_CRMAutoGen_groupby_column_Num_0"> 
      <measurecollection> 
      <measure alias="_CRMAutoGen_aggregate_column_Num_0" /> 
      </measurecollection> 
     </category> 
     </categorycollection> 
    </datadefinition> 
    </datadescription> 
    <presentationdescription> 
    <Chart Palette="None" PaletteCustomColors="91,151,213; 237,125,49; 160,116,166; 255,192,0; 68,114,196; 112,173,71; 37,94,145; 158,72,14; 117,55,125; 153,115,0; 38,68,120; 67,104,43; 124,175,221; 241,151,90; 186,144,192; 255,205,51; 105,142,208; 140,193,104; 50,125,194; 210,96,18; 150,83,159; 204,154,0; 51,90,161; 90,138,57;"> 
     <Series> 
     <Series ChartType="Column" IsValueShownAsLabel="True" Font="{0}, 9.5px" LabelForeColor="59, 59, 59" CustomProperties="PointWidth=0.75, MaxPixelPointWidth=40" /> 
     </Series> 
     <ChartAreas> 
     <ChartArea BorderColor="White" BorderDashStyle="Solid"> 
      <AxisY LabelAutoFitMinFontSize="8" TitleForeColor="59, 59, 59" TitleFont="{0}, 10.5px" LineColor="165, 172, 181" IntervalAutoMode="VariableCount"> 
      <MajorGrid LineColor="239, 242, 246" /> 
      <MajorTickMark LineColor="165, 172, 181" /> 
      <LabelStyle Font="{0}, 10.5px" ForeColor="59, 59, 59" /> 
      </AxisY> 
      <AxisX LabelAutoFitMinFontSize="8" TitleForeColor="59, 59, 59" TitleFont="{0}, 10.5px" LineColor="165, 172, 181" IntervalAutoMode="VariableCount"> 
      <MajorTickMark LineColor="165, 172, 181" /> 
      <MajorGrid LineColor="Transparent" /> 
      <LabelStyle Font="{0}, 10.5px" ForeColor="59, 59, 59" /> 
      </AxisX> 
     </ChartArea> 
     </ChartAreas> 
     <Titles> 
     <Title Alignment="TopLeft" DockingOffset="-3" Font="{0}, 13px" ForeColor="59, 59, 59" /> 
     </Titles> 
     <Legends> 
     <Legend Alignment="Center" LegendStyle="Table" Docking="right" IsEquallySpacedItems="True" Font="{0}, 11px" ShadowColor="0, 0, 0, 0" ForeColor="59, 59, 59" /> 
     </Legends> 
    </Chart> 
    </presentationdescription> 
    <isdefault>false</isdefault> 
</visualization> 

답변

0

당신 만 차트 화면을 변경하려면 변경할 각 시리즈 내부의 LegendText 속성을 사용하려면 다음

<Series ChartType="Column" LegendText="Ongoing" DrawSideBySide= "False" IsValueShownAsLabel="True" Font="{0}, 9.5px" LabelForeColor="59, 59, 59" CustomProperties="PointWidth=0.75, MaxPixelPointWidth=40"> 
    <Series ChartType="Column" LegendText="Cancelled" IsValueShownAsLabel="True" Font="{0}, 9.5px" LabelForeColor="59, 59, 59" CustomProperties="PointWidth=0.75, MaxPixelPointWidth=40"> 

그렇지 않으면 statecode의 optionset가 걸쳐 반영하기 위해 리드 엔티티에 사용자 정의 할 수 있습니다 체계.

+0

제안 해 주셔서 감사합니다. 그러나이 경우 카테고리 선택에 따라 두 개의 막대가 차트에 표시되지만 차트 xml에는 하나의 시리즈 만 있습니다. <시리즈 그래프 유형 = "열"IsValueShownAsLabel = "참"폰트 = "{0} 9.5px"LabelForeColor = "59, 59, 59 'CustomProperties ="PointWidth = 0.75 MaxPixelPointWidth = 40 "/>이 차트 구성에 따라 MSCRM에서 OOB이 생성됩니다. 다른 방법이 있습니까? – Nithya