如何计算按键的按键时间(以毫秒为单位).使用asp.net中的vb在2个键之间的键间延迟时间 [英] How to calculate keyhold time (in milliseconds) of a keypress & inter-key latency time between 2 keys using vb in asp.net

查看:92
本文介绍了如何计算按键的按键时间(以毫秒为单位).使用asp.net中的vb在2个键之间的键间延迟时间的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是asp.net的新手,几个月前刚刚开始自学...
我试图了解如何将我的想法实施到.net编程中.我已经完成了除按键部分之外的所有部分.
我想计算一次按键的按键保持时间(以毫秒为单位),以及两个按键之间的按键间延迟时间.

想法如下:
按下键"A"(按下)-记录键保持时间
按下键"A"(启动)-记录键保持时间
按下键"A"并按下键"B"-记录键间延迟时间

而且,我还需要一些如何将击键数据放入数据库的想法.我还应该记录关键人物吗?
示例:A.down.time || A.up.time || A.B.时间

Tq. . . v(^ _ ^)//

Hi, I''m newbie with asp.net & just have self-learning a few months ago...
I''ve tried to understand how to implement my idea into .net programming. I''ve done all parts except the keystroke part.
I would like to calculate the keyhold time of a keypress in ms & also the inter-key latency time between 2 keys.

The idea is as below:
key ''A'' is pressed (keydown) - record keyhold time
key ''A'' is depressed (keyup) - record keyhold time
key ''A'' is pressed & key ''B'' is depressed - record inter-key latency time

And also, I need ideas how to put my keystroke data into database. Should I record the key character also??
Example: A.down.time || A.up.time || A.B.time

Tq. . . v(^_^)//

推荐答案

.NET确实与它无关.您的事件发生在客户端上,当然要跟踪此类事件,您需要在客户端上使用javascript进行.

您可以按自己喜欢的任何方式存储密钥数据,但是肯定不会一次只存储一个密钥吗?如果是这样,则需要使用AJAX,对于初学者来说,这似乎是另一种麻烦.
.NET really has nothing to do with it. Your events happen on the client, and certainly for you to track things like that, you need to do it on the client, in javascript.

You can store the key data any way you like, but it won''t be one key at a time, surely ? If it is, you''d need to use AJAX, and that seems like another complication for a beginner.


这篇关于如何计算按键的按键时间(以毫秒为单位).使用asp.net中的vb在2个键之间的键间延迟时间的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆