Results 1 to 2 of 2

Thread: Retrieving Database fields through VB6.0 DataReport

  1. #1

    Thread Starter
    New Member
    Join Date
    Mar 2000
    Posts
    1
    Hello,

    I created my database in Visdata through VB6.0. I have a data report created that returns the sum of all the fields entered into my database(ADO). I have my database grouped by month. I can view all the months on my datareport but all I want to see is the one month specified by the user in an input box when they click the report button.
    It would be greatly appreciated if anyone could offer any amount of help because I have tried everything to my knowledge..

    Thank-you

  2. #2
    New Member
    Join Date
    Mar 2000
    Posts
    8
    Here an example of what you must do.

    I set those istructions in the DataReport code

    Private Sub DataReport_Initialize()

    SQL$ = ("Select * from <File> where <field>= '" & <Value> & "'")
    DataEnvironment1.<Recordset>.close
    DataEnvironment1.<Recordset>.open SQL$, DataEnvironment1.<DataEnv>, adOpenStatic, asLockReadOnly, AdCmdText
    End Sub

    Bye

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