hey
i have a mscahrt that displays each month the expenses its calles ExpCost
now i added another one that its called ExpQuantity
how do i add another bar next to the ExpCost?
i dont want to sum ExpCost and ExpQuantity together
i want ExpQauntity to be in a diffrent bar but in the same mschart next to the ExpCost.
this is my code
i have a mscahrt that displays each month the expenses its calles ExpCost
now i added another one that its called ExpQuantity
how do i add another bar next to the ExpCost?
i dont want to sum ExpCost and ExpQuantity together
i want ExpQauntity to be in a diffrent bar but in the same mschart next to the ExpCost.
this is my code
Code:
Dim r As New ADODB.Recordset
CmbChType.text = CmbChType.List(0)
CmbChStyle.text = CmbChStyle.List(0)
r.Open "SELECT Format(ExpDate, ""mmmmyyyy"") As ExpMonth, SUM(ExpCost)FROM Expenses Group By Format(ExpDate, ""mmmmyyyy"")", CN, adOpenKeyset
If r.EOF Then Exit Sub
ReDim arrMn(1 To r.RecordCount, 1 To 3)
For I = 1 To r.RecordCount
arrMn(I, 1) = r.Fields(0)
arrMn(I, 2) = r.Fields(1)
r.MoveNext
Next
MSChart.ChartData = arrMn
r.Close