i designed a database when i didn't know that pressing the ESC key on a form , twice, will delete my AutoNumber, and will give me a nightmare, .... , is there any way of byepassing/ disabling, the ESC key.
Thanks in advance.
Why will it give you a nightmare? Autonumbers should only be used as a unique reference, not a guaranteed sequential number, you'll have to use a user defined function to do that
Why will it give you a nightmare? Autonumbers should only be used as a unique reference, not a guaranteed sequential number, you'll have to use a user defined function to do that
thanks, but i was looking for an easy way out ...
... nightmare because it is being used for relating, the jumping of index key no. will not fetch the record, ....
yeh, relating rows in more than two tables, each table being filled in by separate form ( more like, non-relational, flat files. when the gap occurs in one form/table due to UNDO by ESC key, nightmare starts .... Best short term solution for me would have been a fix for the ESC key . ... ( just disable it ) .. any solutions, .. anyway thanx for the answer(s) .. and in advance ..
If you are expecting to join an autonumber from one table to an autonumber from another, you have a concept problem.
To create a relationship between two tables, you need to take the primary key of one table and record it in a column (defined as long integer) of the second table. A typical example is relating an Order to the customer that placed it. You would add the CustomerID, which is the primary key of the customer table, as a column in the Order table. In the Order table, the CustomerID is referred to as a "foreign key". When you need to obtain the customer information to print an order, you would join the order table to the customer table on customerID.
If you are expecting to join an autonumber from one table to an autonumber from another, you have a concept problem.
OK, maybe, it is a concept problem ..
anyway, the tables are more like one flat file and are linked not as related by keys,... only that the autonumber fields identify the positions as to select records from different tables, so as to complete the record, i hope i have made it clear, ... And, when the autonumber jumps, due to the ESC, my nightmare starts ..
cippy, it does not make logical sense to relate separate tables on their autonumbers. Autonumbers are independently assigned and do nothing but uniquely identify a record.
If you care to supply more details, I'm sure someone can offer an alternative.
I am just curious if at all there is a way to disable ESC key.
My problem is I have a messagebox with OK and CANCEL button...When the user hits ESC...the msgbox disappears but when I execute the code that displays the msgbox again, it will not come up.
I think ESC only shifts the focus..
Even if anyone can offer me a different solution, I still would like to know if ESC key can be disabled.