Ok, my first stumpper. I am working on the coding for the ProductList box on the Customer Form, and I got a type mismatch error. I looked at the code I placed in the Build Event, and it looks the same as the video and the handbook. Although I will not swear by it because the more I look at it and search for Type Mismatch, I become even more confused. What causes this mismatch thing, and if nothing is misspelled, why do I get this message?
Ken WykoffOP
@Reply 10 months ago
Ken WykoffOP
@Reply 10 months ago
Ken WykoffOP
@Reply 10 months ago
Kevin Robertson
@Reply 10 months ago
Is ProductID a number (Long Integer) in CustomerInterestT?
Sandra Truax
@Reply 10 months ago
Keep going in the video because at first, it did not work for Richard either. Then he fixed it.
Sandra Thank you, Sandra, and I will look for that too. I saw he fixed one by adding the CLNG, but this warning came before his fix on that. So he must have found this after that.
Donald Blackwell
@Reply 10 months ago
Since it highlighted "Set db = CurrentDb", double check your Dim statement just to make sure Intellisense didn't pop something in other than "database" while you were typing. I've been getting some crazy things popping in there when I just let the VBEditor finish the word for me. Sometimes it will just put "DAO", sometimes "database" or "databases" or "DBEngine".
Type mismatch is telling you that you're comparing two different kinds of variables, or at least Access thinks you are. Or that you have declared one type but you're trying to set it to another.
Ken WykoffOP
@Reply 10 months ago
Thanks Donald for replying. I did look above at the DIM like you said and instead of Database it was Datebase. Funny that it never spotted that before this. That's one more thing I need to watch for. The other thing I've learned to watch is that it wants to type in re instead of rs. Is there a way to shut off that Intellisense thing in Access? Just curious. Ken
Sorry, only students may add comments.
Click here for more
information on how you can set up an account.
If you are a Visitor, go ahead and post your reply as a
new comment, and we'll move it here for you
once it's approved. Be sure to use the same name and email address.
This thread is now CLOSED. If you wish to comment, start a NEW discussion in
Access Developer 19.