Quantcast
Channel: VBForums - Visual Basic 6 and Earlier
Viewing all articles
Browse latest Browse all 21264

[RESOLVED] how to show a month in mschart

$
0
0
hey
im trying to show my expenses each month that pases by in the mschart
so far i have only done the expenses
this is the code that i have
Code:

Dim R As New ADODB.Recordset
    CmbChType.text = CmbChType.List(0)
    CmbChStyle.text = CmbChStyle.List(0)
   
    R.Open "SELECT SUM(ExpCost)FROM Expenses", CN, adOpenKeyset
   
    If R.EOF Then Exit Sub
    ReDim arrMn(1 To R.RecordCount, 1 To 1)
    For I = 1 To R.RecordCount
        arrMn(I, 1) = R.Fields(0)
     
        R.MoveNext
    Next
    MSChart.ChartData = arrMn

these are my fields in the database and there values

ExpID - number ExpDate - Date/time ExpType-text ExpQuantity-number ExpCost-currency ExpInvoice-text ExpPament-text

ExpCredit-text ExpBank-text ExpFinal-text ExpRemarks-text ExpCardName-text.

i dont know if its relevnt all this fields
but just in case

Viewing all articles
Browse latest Browse all 21264

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>