Keys pressed

Technical support and scripting issues

Moderators: Dorian (MJT support), JRL

Post Reply
math22
Newbie
Posts: 12
Joined: Sun Dec 03, 2017 1:00 am

Keys pressed

Post by math22 » Sat Dec 09, 2017 4:48 pm

Is possible do a script to save keys being pressed in .txt file, with the hour min and secs when the key was pressed.


Like~~~

Keys.txt

Code: Select all

14:46:01 Rdown
14:46:02 Rup
14:46:02 LCtrl
14:46:03 LShift+C
14:46:03 LShift+D
14:46:03 LShift+F
14:46:04 F2
14:46:04 E
14:46:04 E
14:46:04 F
14:46:05 Down
14:46:04 Enter
14:46:04 G
14:46:04 H
14:46:04 H
14:46:04 WF
14:46:04 FFFFF
14:46:04 SF

User avatar
Marcus Tettmar
Site Admin
Posts: 7395
Joined: Thu Sep 19, 2002 3:00 pm
Location: Dorset, UK
Contact:

Re: Keys pressed

Post by Marcus Tettmar » Mon Dec 11, 2017 1:07 pm

No, not really. Macro Scheduler is not designed to be a key logger.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?

User avatar
Djek
Pro Scripter
Posts: 148
Joined: Sat Feb 05, 2005 11:35 pm
Location: Holland
Contact:

Re: Keys pressed

Post by Djek » Sat Dec 16, 2017 4:06 pm

hi,

take a look at this script, maybe you can modify and use it.
it detects the event of keypress, and logs the key into a txt file.

Code: Select all

//Keylogger
CreateDir>c:\log
CreateDir>c:\log\screen
let>uitpad=c:\log\screen
//goto>maakroutine
let>IGNOREERRORS=1
let>WLN_NOCRLF=1
let>lkt=2
let>lastkeytime=lkt
let>teller=32
label>volgendeteller
if>{(%teller%>64) AND (%teller%<91)}
  let>asciteller=%teller%+32
  OnEvent>KEY_DOWN,VK%teller%,0,GETKEY%asciteller%
  OnEvent>KEY_DOWN,VK%teller%,1,GETKEY%teller%
 else
  OnEvent>KEY_DOWN,VK%teller%,0,GETKEY%teller%
  let>toller=%teller%-16
  OnEvent>KEY_DOWN,VK%teller%,1,GETKEY%toller%
endif
let>teller=teller+1
if>teller<127
  goto>volgendeteller
endif

Label>LOOPP
 wait>0.1
 let>lastkeytime=%lastkeytime%-1
 if>lastkeytime<0
   let>lastkeytime=0
 endif
 GetDate>datum
 CreateDir>c:\log\screen\%datum%
goto>LOOPP


SRT>GETKEY32
 if>lastkeytime<1
   VBEval>chr(32),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY32

SRT>GETKEY33
 if>lastkeytime<1
   VBEval>chr(33),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY33

SRT>GETKEY34
 if>lastkeytime<1
   VBEval>chr(34),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY34

SRT>GETKEY35
 if>lastkeytime<1
   VBEval>chr(35),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY35

SRT>GETKEY36
 if>lastkeytime<1
   VBEval>chr(36),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY36

SRT>GETKEY37
 if>lastkeytime<1
   VBEval>chr(37),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY37

SRT>GETKEY38
 if>lastkeytime<1
   VBEval>chr(38),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY38

SRT>GETKEY39
 if>lastkeytime<1
   VBEval>chr(39),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY39

SRT>GETKEY40
 if>lastkeytime<1
   VBEval>chr(40),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY40

SRT>GETKEY41
 if>lastkeytime<1
   VBEval>chr(41),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY41

SRT>GETKEY42
 if>lastkeytime<1
   VBEval>chr(42),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY42

SRT>GETKEY43
 if>lastkeytime<1
   VBEval>chr(43),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY43

SRT>GETKEY44
 if>lastkeytime<1
   VBEval>chr(44),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY44

SRT>GETKEY45
 if>lastkeytime<1
   VBEval>chr(45),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY45

SRT>GETKEY46
 if>lastkeytime<1
   VBEval>chr(46),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY46

SRT>GETKEY47
 if>lastkeytime<1
   VBEval>chr(47),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY47

SRT>GETKEY48
 if>lastkeytime<1
   VBEval>chr(48),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY48

SRT>GETKEY49
 if>lastkeytime<1
   VBEval>chr(49),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY49

SRT>GETKEY50
 if>lastkeytime<1
   VBEval>chr(50),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY50

SRT>GETKEY51
 if>lastkeytime<1
   VBEval>chr(51),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY51

SRT>GETKEY52
 if>lastkeytime<1
   VBEval>chr(52),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY52

SRT>GETKEY53
 if>lastkeytime<1
   VBEval>chr(53),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY53

SRT>GETKEY54
 if>lastkeytime<1
   VBEval>chr(54),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY54

SRT>GETKEY55
 if>lastkeytime<1
   VBEval>chr(55),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY55

SRT>GETKEY56
 if>lastkeytime<1
   VBEval>chr(56),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY56

SRT>GETKEY57
 if>lastkeytime<1
   VBEval>chr(57),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY57

SRT>GETKEY58
 if>lastkeytime<1
   VBEval>chr(58),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY58

SRT>GETKEY59
 if>lastkeytime<1
   VBEval>chr(59),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY59

SRT>GETKEY60
 if>lastkeytime<1
   VBEval>chr(60),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY60

SRT>GETKEY61
 if>lastkeytime<1
   VBEval>chr(61),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY61

SRT>GETKEY62
 if>lastkeytime<1
   VBEval>chr(62),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY62

SRT>GETKEY63
 if>lastkeytime<1
   VBEval>chr(63),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY63

SRT>GETKEY64
 if>lastkeytime<1
   VBEval>chr(64),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY64

SRT>GETKEY65
 if>lastkeytime<1
   VBEval>chr(65),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY65

SRT>GETKEY66
 if>lastkeytime<1
   VBEval>chr(66),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY66

SRT>GETKEY67
 if>lastkeytime<1
   VBEval>chr(67),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY67

SRT>GETKEY68
 if>lastkeytime<1
   VBEval>chr(68),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY68

SRT>GETKEY69
 if>lastkeytime<1
   VBEval>chr(69),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY69

SRT>GETKEY70
 if>lastkeytime<1
   VBEval>chr(70),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY70

SRT>GETKEY71
 if>lastkeytime<1
   VBEval>chr(71),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY71

SRT>GETKEY72
 if>lastkeytime<1
   VBEval>chr(72),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY72

SRT>GETKEY73
 if>lastkeytime<1
   VBEval>chr(73),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY73

SRT>GETKEY74
 if>lastkeytime<1
   VBEval>chr(74),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY74

SRT>GETKEY75
 if>lastkeytime<1
   VBEval>chr(75),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY75

SRT>GETKEY76
 if>lastkeytime<1
   VBEval>chr(76),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY76

SRT>GETKEY77
 if>lastkeytime<1
   VBEval>chr(77),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY77

SRT>GETKEY78
 if>lastkeytime<1
   VBEval>chr(78),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY78

SRT>GETKEY79
 if>lastkeytime<1
   VBEval>chr(79),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY79

SRT>GETKEY80
 if>lastkeytime<1
   VBEval>chr(80),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY80

SRT>GETKEY81
 if>lastkeytime<1
   VBEval>chr(81),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY81

SRT>GETKEY82
 if>lastkeytime<1
   VBEval>chr(82),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY82

SRT>GETKEY83
 if>lastkeytime<1
   VBEval>chr(83),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY83

SRT>GETKEY84
 if>lastkeytime<1
   VBEval>chr(84),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY84

SRT>GETKEY85
 if>lastkeytime<1
   VBEval>chr(85),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY85

SRT>GETKEY86
 if>lastkeytime<1
   VBEval>chr(86),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY86

SRT>GETKEY87
 if>lastkeytime<1
   VBEval>chr(87),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY87

SRT>GETKEY88
 if>lastkeytime<1
   VBEval>chr(88),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY88

SRT>GETKEY89
 if>lastkeytime<1
   VBEval>chr(89),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY89

SRT>GETKEY90
 if>lastkeytime<1
   VBEval>chr(90),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY90

SRT>GETKEY91
 if>lastkeytime<1
   VBEval>chr(91),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY91

SRT>GETKEY92
 if>lastkeytime<1
   VBEval>chr(92),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY92

SRT>GETKEY93
 if>lastkeytime<1
   VBEval>chr(93),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY93

SRT>GETKEY94
 if>lastkeytime<1
   VBEval>chr(94),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY94

SRT>GETKEY95
 if>lastkeytime<1
   VBEval>chr(95),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY95

SRT>GETKEY96
 if>lastkeytime<1
   VBEval>chr(96),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY96

SRT>GETKEY97
 if>lastkeytime<1
   VBEval>chr(97),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY97

SRT>GETKEY98
 if>lastkeytime<1
   VBEval>chr(98),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY98

SRT>GETKEY99
 if>lastkeytime<1
   VBEval>chr(99),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY99

SRT>GETKEY100
 if>lastkeytime<1
   VBEval>chr(100),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY100

SRT>GETKEY101
 if>lastkeytime<1
   VBEval>chr(101),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY101

SRT>GETKEY102
 if>lastkeytime<1
   VBEval>chr(102),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY102

SRT>GETKEY103
 if>lastkeytime<1
   VBEval>chr(103),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY103

SRT>GETKEY104
 if>lastkeytime<1
   VBEval>chr(104),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY104

SRT>GETKEY105
 if>lastkeytime<1
   VBEval>chr(105),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY105

SRT>GETKEY106
 if>lastkeytime<1
   VBEval>chr(106),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY106

SRT>GETKEY107
 if>lastkeytime<1
   VBEval>chr(107),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY107

SRT>GETKEY108
 if>lastkeytime<1
   VBEval>chr(108),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY108

SRT>GETKEY109
 if>lastkeytime<1
   VBEval>chr(109),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY109

SRT>GETKEY110
 if>lastkeytime<1
   VBEval>chr(110),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY110

SRT>GETKEY111
 if>lastkeytime<1
   VBEval>chr(111),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY111

SRT>GETKEY112
 if>lastkeytime<1
   VBEval>chr(112),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY112

SRT>GETKEY113
 if>lastkeytime<1
   VBEval>chr(113),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY113

SRT>GETKEY114
 if>lastkeytime<1
   VBEval>chr(114),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY114

SRT>GETKEY115
 if>lastkeytime<1
   VBEval>chr(115),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY115

SRT>GETKEY116
 if>lastkeytime<1
   VBEval>chr(116),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY116

SRT>GETKEY117
 if>lastkeytime<1
   VBEval>chr(117),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY117

SRT>GETKEY118
 if>lastkeytime<1
   VBEval>chr(118),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY118

SRT>GETKEY119
 if>lastkeytime<1
   VBEval>chr(119),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY119

SRT>GETKEY120
 if>lastkeytime<1
   VBEval>chr(120),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY120

SRT>GETKEY121
 if>lastkeytime<1
   VBEval>chr(121),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY121

SRT>GETKEY122
 if>lastkeytime<1
   VBEval>chr(122),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY122

SRT>GETKEY123
 if>lastkeytime<1
   VBEval>chr(123),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY123

SRT>GETKEY124
 if>lastkeytime<1
   VBEval>chr(124),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY124

SRT>GETKEY125
 if>lastkeytime<1
   VBEval>chr(125),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY125

SRT>GETKEY126
 if>lastkeytime<1
   VBEval>chr(126),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY126

SRT>GETKEY127
 if>lastkeytime<1
   VBEval>chr(127),char
   WriteLn>c:\log\screen\%datum%\%datum%.txt,ert,char
   let>lastkeytime=lkt
 endif
END>GETKEY127

label>einde
The actual script is short but it consists of several subroutine events per keycode,
if you want to change these subroutines , you can use this script:

Code: Select all

label>maakroutine
CreateDir>c:\log
CreateDir>c:\log\screen
let>uitpad=c:\log\screen
DeleteFile>%uitpad%\routine.txt
let>teller=31
label>meer
let>teller=%teller%+1
WriteLn>%uitpad%\routine.txt,ert,SRT>GETKEY%teller%
WriteLn>%uitpad%\routine.txt,ert, if>lastkeytime<1
WriteLn>%uitpad%\routine.txt,ert,   VBEval>chr(%teller%),char
WriteLn>%uitpad%\routine.txt,ert,   WriteLn>%uitpad%\%datum%\%datum%.txt,ert,char
WriteLn>%uitpad%\routine.txt,ert,   let>lastkeytime=lkt
WriteLn>%uitpad%\routine.txt,ert, endif
WriteLn>%uitpad%\routine.txt,ert,END>GETKEY%teller%
WriteLn>%uitpad%\routine.txt,ert,
if>teller<127
  goto>meer
endif
MessageModal>klaar
ExecuteFile>%uitpad%\routine.txt
label>einde

and then copy / paste the result of routine.txt into the first script

kind regards,
Djek

Post Reply
Sign up to our newsletter for free automation tips, tricks & discounts