CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Nov 1998
    Posts
    8

    How to display the running sums in VB?



    there are lot of ways in sql to diplay the running sums and sums(using group by,compute by, compute etc.,). Ok I have written one like. but How to create the resultset containing those running sums.

  2. #2
    Join Date
    Apr 1999
    Location
    Rotterdam, Netherlands
    Posts
    278

    Re: How to display the running sums in VB?



    I don't know how to do it with the datacontrols, but if you do it manually:

    Dim db as Database

    Dim rs as Recordset

    Set db = OpenDatabase( MyDatabase.mdb, False)

    Set rs = db.OpenRecordset( , dbOpenDynaset, dbReadOnly)

    Now you can simply do a loop like

    Do While Not rs.EOF

    rs.Fields(0).Value

    Loop


    Check the help for the stuff you don;t know.. This is out of my head, but it's something real close to the above.


    hope it helps

    Crazy D

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured