type mismatch

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I get a "Type mismatch" on the following lines:

Dim frm as form

If frm Is Nothing Then
Set frm = Me.frmList2
End If

frmList2 is a subform and spelled correctly. This code works other places. ??

Thanks so much!
 
I'm guessing that frmList2 is a subform control. You refer to the form in
the subform control with the .Form property, so you need:
Set frm = Me.frmList2.Form

More info:
Referring to Controls on a Subform
at:
http://allenbrowne.com/casu-04.html
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top