Hi all, I have a table with an AutoInc integer for a keyfield. The table has another field which is a code. There is a key on that second field. I have a report that prints records from this table. On the request form I want let the user look up values in the second column rather than having to guess or type blind. I’m thinking because the value is not coming from another table and/or because it isn’t part of the primary key that I’m not getting a lookup. I tried overriding the OnLookup in the table but that’s not allowing the lookup button on the report request form. Any ideas? Django
Hi, Why not you are trying to put same code in OnLookup trigger of filed on Request Form.
Sorry - when I said Request Form I meant to say the filter value on the tab for the table. Where you would set the filter on a field. Regards, Django
Django, You are correct in your interpretation of the problem. To use a lookup the field must reference a key in another table.
hi guys, i cant see the problem, OnLookup from the codefield: CLEAR(myTabfrm); myRec.RESET(); myTabfrm.SETTABLEVIEW(myRec) ; myTabfrm.LOOKUPMODE(TRUE) ; IF myTabfrm.RUNMODAL = ACTION::LookupOK THEN BEGIN myTabfrm.GETRECORD(myRec); SETFILTER(text,myRec.text); END;