Re: arrghh dot vs comma
Thank you Cor,
I am happy that you understand the problem :-)
i have just found a workaround that unfortanitly is not exactly what i want
if i add this key to the registry
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACH INE\SYSTEM\Curr entControlSet\C ontrol\Keyboard Layout]
"Scancode Map"=hex:00,00, 00,00,00,00,00, 00,02,00,00,00, 33,00,53,00,00, 00,00,00
it works great , however waht if the user changes his settings to for
instance US settings ?? well the dot will then still produce a , so he needs
to remove the registry key
also a problem is that the user should log off and log on before the added
key takes effect
it would be much nicer if there is a way to simulate the behavior on program
start and remove it on program end
or as you mentioned if it is possible to trap the key events on certain
columns in the datagridview and change the numeric dot for a comma this
would be nice , overall trapping wouldn`t work as it must be possible to
enter in a text column in the datagrid M. Posseth and in the column besides
it 8,99
where the dot after M. is made with >. key and the 8,99 is made with
the del. key ofcourse it is no problem if del. key creates in the first
column a . and in the second wich holds numeric values creates a ,
regards
Michel Posseth
"Cor Ligthert [MVP]" wrote:
[color=blue]
> Michel,
>
> I thought trying to to this problem for you today, I am not sure if I have
> time for that because I go out in some minutes.
>
> It would be based on the fact that you can cast a textbox in a datagrid and
> use its events.
>
> I would use the keyup event and watch if the value is a dot and replace that
> than by a comma and a comma by a dot. (You have than to play with the
> selected position and things like that, but I assume that you know that,
> there are plenty of samples in this newsgroup about the numeric textbox and
> in fact do you have to extend that).
>
> I had the idea that I did something before.
>
> Cor
>
>
>[/color]
Thank you Cor,
I am happy that you understand the problem :-)
i have just found a workaround that unfortanitly is not exactly what i want
if i add this key to the registry
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACH INE\SYSTEM\Curr entControlSet\C ontrol\Keyboard Layout]
"Scancode Map"=hex:00,00, 00,00,00,00,00, 00,02,00,00,00, 33,00,53,00,00, 00,00,00
it works great , however waht if the user changes his settings to for
instance US settings ?? well the dot will then still produce a , so he needs
to remove the registry key
also a problem is that the user should log off and log on before the added
key takes effect
it would be much nicer if there is a way to simulate the behavior on program
start and remove it on program end
or as you mentioned if it is possible to trap the key events on certain
columns in the datagridview and change the numeric dot for a comma this
would be nice , overall trapping wouldn`t work as it must be possible to
enter in a text column in the datagrid M. Posseth and in the column besides
it 8,99
where the dot after M. is made with >. key and the 8,99 is made with
the del. key ofcourse it is no problem if del. key creates in the first
column a . and in the second wich holds numeric values creates a ,
regards
Michel Posseth
"Cor Ligthert [MVP]" wrote:
[color=blue]
> Michel,
>
> I thought trying to to this problem for you today, I am not sure if I have
> time for that because I go out in some minutes.
>
> It would be based on the fact that you can cast a textbox in a datagrid and
> use its events.
>
> I would use the keyup event and watch if the value is a dot and replace that
> than by a comma and a comma by a dot. (You have than to play with the
> selected position and things like that, but I assume that you know that,
> there are plenty of samples in this newsgroup about the numeric textbox and
> in fact do you have to extend that).
>
> I had the idea that I did something before.
>
> Cor
>
>
>[/color]
Comment