MsgBox not working in code

If cmb_yrqtr = Null Then
MsgBox "You must select a year/qtr", vbExclamation, "Sorry!"


Else
DoCmd.OpenQuery "Mtbl_AllIndicatorfilter", acViewNormal, acEdit


When I put a break on the line 'If cmb_yrqtr = Null Then'  i can see that 'cmb_yrqtr' = Null-
so why isn't my msgbox popping up?

smoschkauAsked:
Who is Participating?
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
If isnull(cmb_yrqtr ) Then
0
 
NightmanCTOCommented:
What data type is cmb_yrqtr?
0
 
smoschkauAuthor Commented:
I think numeric??

In the colum I have -1 and 2005_3

The combo box comes from a union query-
0
 
smoschkauAuthor Commented:
Thanks angel! That worked GREAT!
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.