-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy path__GENERAL.au3
executable file
·69 lines (55 loc) · 1.86 KB
/
__GENERAL.au3
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
#cs ----------------------------------------------------------------------------
AutoIt Version: 3.3.8.1
Author: Alexander Alvonellos
Script Function:
Template AutoIt script.
#ce ----------------------------------------------------------------------------
#include-once
#include <File.au3>
#include <Date.au3>
; AutoItSetOption("MustDeclareVars", 1)
Func __GENERAL__CERR($message)
Local $hFile = FileOpen(@ScriptDir & "\" & @ComputerName & ".txt", 1) ; Append
_FileWriteLog($hFile, @ComputerName & " :: " & $message)
FileFlush($hFile)
FileClose($hfile)
EndFunc
Func __GENERAL__TIMESTAMP($cDateDelimiter = "-", $cDateTimeDelimiter = "@", _
$cTimeDelimiter = ":", $cMSecDelimiter = ".")
Local $comb = ""
$comb &= $cDateDelimiter & @MON
$comb &= $cDateDelimiter & @MDAY
$comb &= $cDateTimeDelimiter & @HOUR
$comb &= $cTimeDelimiter & @MIN
$comb &= $cTimeDelimiter & @SEC
$comb &= $cMSecDelimiter & @MSEC
Return $comb
EndFunc
; This function returns the current
; epoch time.
Func __GENERAL__EPOCH()
Return _DateDiff('s', "1970/01/01 00:00:00", _NowCalc())
EndFunc
;; Left off here 071612
;; http://www.phy.mtu.edu/~suits/notefreqs.html
Func __GENERAL__PLAY_NOTE_A($iDurationMillisec = 200)
Beep(440,$iDurationMillisec)
EndFunc
Func __GENERAL__PLAY_NOTE_B($iDurationMillisec = 200)
Beep(495,$iDurationMillisec)
EndFunc
Func __GENERAL__PLAY_NOTE_C($iDurationMillisec = 200)
Beep(528,$iDurationMillisec)
EndFunc
Func __GENERAL__PLAY_NOTE_D($iDurationMillisec = 200)
Beep(594,$iDurationMillisec)
EndFunc
Func __GENERAL__PLAY_NOTE_E($iDurationMillisec = 200)
Beep(660,$iDurationMillisec)
EndFunc
Func __GENERAL__PLAY_NOTE_F($iDurationMillisec = 200)
Beep(704,$iDurationMillisec)
EndFunc
Func __GENERAL__PLAY_NOTE_G($iDurationMillisec = 200)
Beep(783,$iDurationMillisec)
EndFunc