How to add a text on bar graph in Visual Lansa for Web

This Q&A forum allows users to post and respond to "How Do I Do ....." questions. Please do not use to report (suspected) errors - you must use your regional help desk for this. The information contained in this forum has not been validated by LANSA and, as such, LANSA cannot guarantee the accuracy of the information.
Post Reply
afzalauzam
Posts: 1
Joined: Wed Oct 25, 2023 5:49 am

How to add a text on bar graph in Visual Lansa for Web

Post by afzalauzam »

Hi,

Can any one please let me know how to add a text on a Bar Graph in Lansa for Web. Similar to the attached image.
See below sample VL code. Any help is highly appreciated.

Thank you,
Afzal.


* Bar Chart 2D
Define_Com Class(#PRIM_CHRT.BarChart) Name(#BarChart2D) Displayposition(12) Height(448) Left(195) Legendposition(Right) Parent(#COM_OWNER) Tabposition(12) Tabstop(False) Top(150) Width(803)
Define_Com Class(#PRIM_CHRT.BarChartCaption) Name(#Bar2DChartCaption) Parent(#BarChart2D)
Define_Com Class(#PRIM_CHRT.BarChartValue) Name(#Bar2DChartValue1) Description('Total Sales $') Displayposition(1) Parent(#BarChart2D) Themedrawstyle('MediumTitle')
Define_Com Class(#PRIM_CHRT.BarChartValue) Name(#Bar2DChartValue2) Description('Total Cases') Displayposition(2) Parent(#BarChart2D) Themedrawstyle('MediumAccent') Axis(Secondary)

--------------------------------------------------------------------------------------------------------------------

Mthroutine Name(Load2DBarChart) Access(*PRIVATE)

Clr_List Named(#BarChart2D)

Selectlist Named(#SALDSH)

#Bar2DChartCaption := #YYYYMM.AsString + ' ' + #W_MthDay
#Bar2DChartValue1 := #LDMORTO
#Bar2DChartValue2 := #LDMQTY

Add_Entry To_List(#BarChart2D)

#Bar2DChartValue1.CurrentItem.FormatHint Line1('$' + #LDMORTO.AsDisplayString( EditCode_N ))
#Bar2DChartValue2.CurrentItem.FormatHint Line2(#LDMQTY.AsDisplayString( EditCode_N ))

Endselect

Endroutine
Attachments
BarGraph.png
BarGraph.png (96.2 KiB) Viewed 192164 times
Post Reply