urgent [message #77705] |
Tue, 06 November 2001 01:44  |
lakshmi
Messages: 22 Registered: July 2000
|
Junior Member |
|
|
Hi All,
I was struck up with the following logic:
I had a control item (TRANSACTION_TYPE) in one block and database items in other block.
when i enter 'cash' in TRANSACTION_TYPE and some details in database fields and clicking a button it inserts into database.
but i should not insert the same TRANSACTION_TYPE(cash) again.
if i try to insert again a message pops up 'can't insert same'
what i want???????
when i type 'ca%' and press tab,i want to see the details inserted for 'cash' and when i press 'DOWN' arrow key the other records contaning 'ca%' should automatically come.
it is easy if the TRANSACTION_TYPE field is a database field but in my case it is a control field.
please give me a solution.
regards,
Lakshmi.
----------------------------------------------------------------------
|
|
|
Re: urgent [message #77708 is a reply to message #77705] |
Tue, 06 November 2001 04:15  |
Pratima
Messages: 2 Registered: November 2001
|
Junior Member |
|
|
Key Next item of TRANSACTION_TYPE field type the following
GO_BLOCK('DATABASEBLOCK');
SET_BLOCK_PROPERTY('DATABASEBLOCK',DEFAULT_WHERE,'TXTYPE = 'cash');
GO_BLOCK('DATABASEBLOCK');
EXECUTE_QUERY;
SET_BLOCK_PROPERTY('DATABASEBLOCK',DEFAULT_WHERE,'');
KEY DOWN TRIGGER AT THE FORM LEVEL type the following
GO_BLOCK('DATABASEBLOCK');
SET_BLOCK_PROPERTY('DATABASEBLOCK',DEFAULT_WHERE,'TXTYPE LIKE :CONTROLBLOCK.TRANSACTION_TYPE');
GO_BLOCK('DATABASEBLOCK');
EXECUTE_QUERY;
SET_BLOCK_PROPERTY('DATABASEBLOCK',DEFAULT_WHERE,'');
Hope this Helps!!!
----------------------------------------------------------------------
|
|
|