• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 151
  • Last Modified:

Method or Data Member not Found error in Access 97

I have used similar code before in Access2000 but I am running into a "Method or Data Member not Found" error when I use the code in Access97. Based on what the user enteres into the catalogue field only those modules pertaining to the selected catalogue would show up in the module field.

Private Sub Module_GotFocus()
Dim strSQL As String

    strSQL = "SELECT Module" & _
        "FROM tbl_Catalogue_Modules WHERE Catalogue= '" & Me![Catalogue] & "'"
       
        Module.RowSource = strSQL
        Module.Requery
       
End Sub
0
Fozzybear
Asked:
Fozzybear
  • 2
1 Solution
 
VinayCommented:
Just try following code....
It seems the same but i have added 1 space between Module & FROM.... hope this should work..

Private Sub Module_GotFocus()
Dim strSQL As String

   strSQL = "SELECT Module" & _
       "FROM tbl_Catalogue_Modules WHERE Catalogue= '" & Me![Catalogue] & "'"
       
       Module.RowSource = strSQL
       Module.Requery
       
End Sub

Keep in touch,
Vini!
vinusa500@yahoo.com
0
 
FozzybearAuthor Commented:
I tried it but still no luck.

The error seems to be centered around RowSource.
0
 
FozzybearAuthor Commented:
I finally figured it out. Having not worked with Access 97 before it seems that it is a little dumb at times compaired with Access 2000, i.e. you have to tell it where everything is.

All I had to do was this

Private Sub Module_GotFocus()
Dim strSQL As String

  strSQL = "SELECT Module" & _
      "FROM tbl_Catalogue_Modules WHERE Catalogue= '" & Me![Catalogue] & "'"
     
      Me![Module].RowSource = strSQL
      Me![Module].Requery
     
End Sub

On a quiet day if you listen real hard you would probably here the sound of me slapping my forhead and saying "why didn't I think of that sooner".
0
 
CleanupPingCommented:
Fozzybear:
This old question needs to be finalized -- accept an answer, split points, or get a refund.  For information on your options, please click here-> http:/help/closing.jsp#1 
Experts: Post your closing recommendations!  Who deserves points here?
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now