Yes (so the conversion error is assigning null to a currency type, SalePrice??)
The next step was to test to see if ImpSalePrice was null.  
Can I not do that?
Mark
On 23 Jul 2003 at 22:39, Moises Lopez wrote:

> mark
> 
> could it be that the SaleRefTable.Lookup somehow is returning null?
> 
> cheers
> moises
> 
> At 11:09 AM 7/24/2003 +1200, you wrote:
> 
> >I am getting an Invalid variant type conversion in the following code:
> >
> >    ImpSalePrice := SaleRefTable.Lookup(
> >       'CustCode;DestCode;PricePoint;SpeciesCode;LogGrade;LogLength',
> >       VarArrayOf([pCustCode, pDestCode, pPricePoint, pSpeciesCode, pLogGrade,
> >       pLogLength]), 'SalePrice');
> >
> >I can't understand it because there is no error with the following:
> >
> >    if SaleRefTable.Locate(
> >       'CustCode;DestCode;PricePoint;SpeciesCode;LogGrade;LogLength',
> >       VarArrayOf([pCustCode, pDestCode, pPricePoint, pSpeciesCode, pLogGrade,
> >       pLogLength]), []) then
> >
> >I have check each of the types in the array and they match those in the 
> >table.  Can
> >anyone point me to what is happening here?
> >
> >TIA
> >
> >Mark
> >---------------------------------------------------------------------------
> >     New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
> >                   Website: http://www.delphi.org.nz
> >To UnSub, send email to: [EMAIL PROTECTED]
> >with body of "unsubscribe delphi"
> >Web Archive at: http://www.mail-archive.com/delphi%40delphi.org.nz/
> >
> >
> >---
> >Incoming mail is certified Virus Free.
> >Checked by AVG anti-virus system (http://www.grisoft.com).
> >Version: 6.0.495 / Virus Database: 294 - Release Date: 6/30/2003
> 


---------------------------------------------------------------------------
    New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
                  Website: http://www.delphi.org.nz
To UnSub, send email to: [EMAIL PROTECTED] 
with body of "unsubscribe delphi"
Web Archive at: http://www.mail-archive.com/delphi%40delphi.org.nz/

Reply via email to