Board index » delphi » HELP!:Invalid Variant Type Conversion

HELP!:Invalid Variant Type Conversion

In an application I'm working on I receive and "Invalid variant type conversion" on
each form every time I click on the Insert button on the DBNavigator attached to the
form.  I cannot add new records.  I don't have a clue why.  Does anyone else ?
--
Brian Corll
brian.co...@paonline.com
http://www.paonline.com/mfolia/index.htm

 

Re:HELP!:Invalid Variant Type Conversion


Quote
Brian Corll wrote:

> In an application I'm working on I receive and "Invalid variant type conversion" on
> each form every time I click on the Insert button on the DBNavigator attached to the
> form.  I cannot add new records.  I don't have a clue why.  Does anyone else ?
> --
> Brian Corll
> brian.co...@paonline.com
> http://www.paonline.com/mfolia/index.htmHello!

  Do you have any code attached to the event-handlers for the
DB components ? if so, be aware of this:
Check all assignments of variant type.
The 'lookup' method for Ttable component can return variant array
if more than one field is specified in 'ResultFields'. If you try
to assign the result to a string variable, the mentioned error is
raised. Put any suspected type-convertion codelines in a try statement.

Atle Markeng

Other Threads