In summary I want to take advantage of the recoding properties of the DDDW
without it being a DDDW.
Here is the problem:
By creating a numeric field with:
Always Show List - checked
Width of drop down - 1%
I can have a field that recodes input, does not show an DDDW arrow or list
and gives me nearly what I want. The only problem is that the up/down
arrow keys which normally move between datawindow rows will instead move
the user between items in the DDDW (that they cannot see) and so the
behaviour of this field is nearly ,but not quite like an edit!
Clearly I can execute this recoding during the retrieveend and updatestart
events but in this case I would be helpful to me to have it work using the
DDDW.
Any bright ideas?
Thanks for your help, in advance.
Mark Jones
Have you looked at overriding the default processing of the down ( or up )
arrow key ? You could create a user event mapped to pbm_dwnkey and check
whether the down arrow was pressed. If so, you can programmatically move the
user to the next row.
HTH
Sanjiv Das [TeamPS]
Mark Jones wrote in message
<01bd05a7$1219cd00$636c1fac@configure_me.damark.com>...
Sanjiv,
When a dddw gets focused, the up arrow and down arrow key will not
trigger the pbm_dwnkey event. The reason is that pbm_dwnkey is dw
event, not a dddw event.
Mark,
If you really want to use the dddw feature, you may track the keydown
event in "other event" by reading the values of message.lparam and
message.wparam. By doing so, you may at first use watcom spy to find out
the value of key down event value and uparrow and downarrow values from
message.lparam and message.wparam, then write some logic in the "other"
event in datawindow.
Another option could be -
Before update the data, translate user-entered data to the data you want
to save.
In order to be transparent to end users, you may translate and update
the data behind datawindow via a datastore.
I am not sure which is easier for you.
HTH,
--
Lijun
===============================================
Lijun Yang Mailto:Ly...@rgti.com
mailto:Lijun...@worldnet.att.net
===============================================