I hope someone can help me with this one. I want the data table in a chart show % values with one decimal place. I formatted the source query field to percent with one decimal, I formatted the chart datasheet field the same and I added the following code to the On Print event for the Detail section of the report where the chart resides:
On Error Resume Next
Dim objGraph As Object
Dim objDS As Object
Set objGraph = Me!rptBttryPrdVsTstStsWSA.Object
Set objDS = objGraph.Application.DataSheet
objDS.Range("C1:C11").NumberFormat = "#.0%"
objGraph.Refresh
DoEvents
Set objGraph = Nothing
But to no avail. This code I got from another forum and it seemed to work for them but not for me. For instance I want to display 14.8% in the data table but with all I did it still displays 0.148412415 . Does anyone have any other ideas on this? "Thank you" in advance.
Dan
Dan Rogotzke
Daniel_Rogotzke@oxy.com
On Error Resume Next
Dim objGraph As Object
Dim objDS As Object
Set objGraph = Me!rptBttryPrdVsTstStsWSA.Object
Set objDS = objGraph.Application.DataSheet
objDS.Range("C1:C11").NumberFormat = "#.0%"
objGraph.Refresh
DoEvents
Set objGraph = Nothing
But to no avail. This code I got from another forum and it seemed to work for them but not for me. For instance I want to display 14.8% in the data table but with all I did it still displays 0.148412415 . Does anyone have any other ideas on this? "Thank you" in advance.
Dan
Dan Rogotzke
Daniel_Rogotzke@oxy.com