Type Mismatch / Displaying Form / setvalue

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

Guest

The current project involves a consolidation of databases that were created
under MS Access 2000 & 2003. I have imported different objects in a new
database file using 2003. My problem is this:

I have a main form that contains a subform that has an option group. When I
click on the option group of the subform it runs a macro that changes source
object of the main form's subform.

The problem I'm having is I get a type mismatch dialog box. The form opens
and I click 'OK' to clear the box. It does not happen all the time. I have
checked the underlying tables and querys to make sure I don't a numeric
field defined as text.

I have used this method several times with great success. It really got
stopped cold as to what is causing this error!

Thoughts?
 
The current project involves a consolidation of databases that were created
under MS Access 2000 & 2003. I have imported different objects in a new
database file using 2003. My problem is this:

I have a main form that contains a subform that has an option group. When I
click on the option group of the subform it runs a macro that changes source
object of the main form's subform.

The problem I'm having is I get a type mismatch dialog box. The form opens
and I click 'OK' to clear the box. It does not happen all the time. I have
checked the underlying tables and querys to make sure I don't a numeric
field defined as text.

I have used this method several times with great success. It really got
stopped cold as to what is causing this error!

Thoughts?

Care to post your code? We can't see it from here.

It's possible that the error is data dependent - for instance, trying to pass
a NULL to some expression that doesn't handle NULL.

John W. Vinson [MVP]
 
John,

Thank you for the reply. I have resolved my own issue. The error was
caused by but the subform. Meaning the value I was getting from the subform
changed before the macro finished running. If you still care to see the code
with the fix Ill be more than happy to post it.
 
Back
Top