I want to say thanks to Allen Browne for his help...
The problem now is as follow....
I have one Form (Invoice) with one subform (Invoice's Details), when
select one client in the cbo of the form, the subform's cbo shows onl
the products by agreement.....
Later, I used DLookup function (as Allen Browne recommended)
DLookup(expression, domain, [criteria]), but I need to use tw
criterias.....I understanded the terms -expression- and - domain-, an
they work good, but when I select the product I need two criteria
because two differents clients can to buy the same product wit
different price.
then I did a querie with needed fields, and I said to criteria of th
DLookup function [criteria1] and [criteria2], then Access said (I
Spanish, sorry) Error 13 No Coinciden los tipos.....
Help me Pleas
--
AndyEduard
mscertified - 29 Nov 2005 22:46 GMT
I dont understand Spanish but the only error I could think of is that a
column name you specified is not in the table you are searching.
Check the syntax of your criteria clause. Are you sure you have the quotes
and brackets in the right place? The [] is supposed to be around table names
or column names not the entire criteria clause.
Dorian
> I want to say thanks to Allen Browne for his help...
>
[quoted text clipped - 15 lines]
>
> Help me Please
John Vinson - 29 Nov 2005 23:20 GMT
>I want to say thanks to Allen Browne for his help...
>
[quoted text clipped - 15 lines]
>
>Help me Please
You can only use one criterion - but that criterion can contain
multiple expressions. It should be a valid SQL WHERE clause without
the word WHERE, and it can contain AND (if you want both of two
criteria to apply) or OR (if you want to look up the value if either
one of the criteria applies). For instance you could use
=DLookUp("[Price]", "[PriceList]", "[CustomerID] = " & [CustomerID] &
" AND [ProductID] = " & [ProductID])
This will produce a single string value such as
[CustomerID] = 319 AND ProductID = 44
when the values in the form are inserted.
I have no idea what your table looks like or what criteria you are
trying to use so I can't give a better example. Post with a
description if you need help.
John W. Vinson[MVP]
AndyEduardo - 30 Nov 2005 17:39 GMT
Thanks to John, I tried as you said and Access did it
Thank you very much for your help. I'm satisfied with your answe
--
AndyEduard