Results 1 to 2 of 2

Thread: Help! What am I doing wrong ?

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Jan 1999
    Posts
    118

    Post

    Private Sub Command2_Click()


    Dim strSQL As String
    strSQL = "SELECT * FROM Customer " & _
    "WHERE (HomePhone = """ & varHomePhone & """);"
    Me.Data1.RecordSource = strSQL
    Me.Data1.Refresh
    If Me.Data1.EOFAction And Me.Data1.BOFAction Then
    AddCust.Show vbModal
    Else

    End If
    End Sub

    I want this code to show a form if ther are no records in this database.
    Any help would be appreciated .

    Thanks Paul (Newbie)

  2. #2
    Frenzied Member
    Join Date
    Aug 1999
    Location
    Santa Clara, Ca , 95058
    Posts
    1,105

    Post

    Don't get hung up on using data controls, you can solve the problem with the answer provided in the topic labelled:

    Topic: How to do this using SQL ? Please help!!

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