Page 1 of 1

"Could not convert variant of type (Null) into type (String)"

Posted: Sat 28 Jan 2006 08:31
by haci
Hi, I use TMSQuery object, and when i use this object with Delphi's Lookup function. When i call this line i take this error message "Could not convert variant of type (Null) into type (String)".

VRNT := tblrights.Lookup('PRJ;UUSER', VarArrayOf([IntToStr(PRJ), IntToStr(user.ID)]) , 'ID;STU');
if not (VarType(VRNT) in [varNull]) then begin
showmessage (VRNT[0] + ' - ' + VRNT[1]);
v := 1;
end;


I didn't find any solution.

Thank you.

Posted: Mon 30 Jan 2006 11:37
by Ikar
Please specify types of all used fields.