14 Commits
d3k ... 2.7

Author SHA1 Message Date
545bdeb506 Update 'emails.example.csv' 2020-01-21 05:09:55 -06:00
330f7f63e7 Update 'func.ahk'
forgot to change the version...
2020-01-21 05:07:29 -06:00
0dd3dc2353 Add dealer org 2020-01-21 05:06:21 -06:00
ea4ddc9f42 add dealer org 2020-01-21 05:05:59 -06:00
fef7d1e376 Add dealer org, fix ini updating 2020-01-21 05:05:31 -06:00
ace6f712cd add function to remove extra empty lines from ini when writing 2020-01-14 10:53:05 -06:00
64d7d9dc0a Update 'Settings.ahk' 2020-01-14 10:05:02 -06:00
0a25a0262a Update 'emails.example.csv' 2020-01-14 09:29:17 -06:00
f182bc2bf2 Update 'emails.example.csv' 2020-01-14 09:18:19 -06:00
6a803b887a Update 'Case_Formatter.ahk' 2020-01-14 09:17:42 -06:00
4d848c4613 Update 'func.ahk' 2020-01-14 09:16:37 -06:00
da3ddfc759 Update 'Settings.ahk' 2020-01-14 09:15:53 -06:00
65d0427f53 Update 'addemail.ahk' 2020-01-14 09:14:48 -06:00
49138d3bea Update 'README.md' 2020-01-14 08:41:05 -06:00
8 changed files with 39 additions and 46 deletions

View File

@ -2,13 +2,11 @@
SetTitleMatchMode, 2
ini = %A_MyDocuments%\D3Ksettings.ini
; These next 3 options make it so that it's always on top, it there are no buttons, and doesn't show up in the alt-tab or taskbar
Gui,+AlwaysOnTop
Gui, +ToolWindow
IniRead, docfile, %ini%, USpec, DocFile, 0
docfile := ini_getValue(ini, "USpec", "DocFile")
CurrTimeEN := GetDateTime("en")
CurrTimeDE := GetDateTime("de")
@ -131,7 +129,7 @@ Write:
FileAppend, Call received %CurrTimeEN%.`n`n, %docfile%
If (Act = "0") ; Not an activation
{
FileAppend,Dealer called for, %docfile%
FileAppend,Dealer called for , %docfile%
}
Else If (Act = "1") ; Warrant
@ -151,7 +149,7 @@ Write:
If (Act = "0") ; Not an activation
{
FileAppend,Händler rief an mit, %docfile%
FileAppend,Händler rief an mit , %docfile%
}
Else If (Act = "1") ; Warrant

14
D3K.ahk
View File

@ -2,11 +2,7 @@
Menu, Tray, Icon, shell32.dll, 283 ; Set the tray icon to a keyboard
SetWorkingDir, %A_MyDocuments%\D3K ; Make sure we can find the .ahks linked below
ini = %A_MyDocuments%\D3Ksettings.ini ; Where the settings ini is
ini_writeValue(ini, "Version", "2.6")
ini_writeValue(ini, "Version", d3k_version)
;------------------------------------------------------------------------------
; Make sure the settings file exists, if not, create it
@ -31,7 +27,7 @@ GloVar=0
[Language]
German=0
[Info]
Version=2.6
Version=0
), %ini%
Run Settings.ahk ; Runs the GUI for changing the settings, also accessible with Alt+Shift+\ (also easy way to restart this script)
}
@ -142,15 +138,16 @@ If (glovar = 1)
if !(REValue = dealinfo.xid)
{
run addemail.ahk
Break
Continue
}
; Replace the data in glovar.ahk with the data from the ini
FileRead, tempglovar, glovar.ahk
tempglovar := RegExReplace(tempglovar, "(?<=\$xid::).*", dealinfo.xid)
tempglovar := RegExReplace(tempglovar, "(?<=\$dem::).*", dealinfo.email)
tempglovar := RegExReplace(tempglovar, "(?<=\$dnm::).*", dealinfo.name)
tempglovar := RegExReplace(tempglovar, "(?<=\$dus::).*", dealinfo.user)
tempglovar := RegExReplace(tempglovar, "(?<=\$xid::).*", dealinfo.xid)
tempglovar := RegExReplace(tempglovar, "(?<=\$dorg::).*", dealinfo.org)
FileAppend, %tempglovar%, tempglovar
FileCopy, tempglovar, glovar.ahk,1
FileDelete, tempglovar
@ -569,6 +566,7 @@ SetTitleMatchMode, 2
::pmcalc::PMCalc
::vat::VAT
:*:racf::RACF
::igrade::iGrade
; German

View File

@ -1,6 +1,6 @@
# Welcome To David3000
This was made By David Daily to replace text and do text correction for John Deere GSC Employees. All Credit for the name goes to William Cross (RIP).
This was by me to replace text and do text correction at work. All Credit for the name goes to William Cross (RIP).
**`Alt+Shift+\` to open a settings window to easily change your settings**
## **`Alt+Shift+\` to open a settings window to easily change your settings**
You can find the rest of the info in [the wiki tab up there](https://daviddaily.dev/david/d3k/wiki)
### You can find the rest of the info in [the wiki tab up there](https://daviddaily.dev/david/d3k/wiki)

View File

@ -1,13 +1,9 @@
#SingleInstance force ; Only one instance at a time
SendMode, Input
FileEncoding, UTF-8 ; Makes sure the special characters don't break stuff
#Include, func.ahk
Menu, Tray, Icon, shell32.dll, 283
;------------------------------------------------------------------------------
; Read ini
;------------------------------------------------------------------------------
ini = %A_MyDocuments%\D3Ksettings.ini
/*
This is the part that reads the file to see what your settings are. Variables in the ini file are in CamelCase, variables here are lowercase for more distinction
*/
@ -52,10 +48,9 @@ Gui, Add, CheckBox, x12 y95 w100 h30 vformMansol Checked%mansol% gMansol, ManSol
Gui, Add, CheckBox, x12 y125 w100 h30 vformMJDPaste Checked%mjdpaste% gMJDPaste, MJDPaste
Gui, Add, CheckBox, x12 y155 w100 h30 vformCaseFormatter Checked%caseformatter% gCaseFormatter, Case Formatter
Gui, Add, GroupBox, x128 y83 w157 h105, Text Replacement
Gui, Add, CheckBox, x132 y95 w150 h30 vformSymb Checked%symb% gSymb, Symbols
Gui, Add, CheckBox, x132 y125 w150 h30 vformJdpn Checked%jdpn% gJdpn, JD Product Names
Gui, Add, CheckBox, x132 y155 w150 h30 vformGlovar Checked%glovar% gGlovar, Global Variables
Gui, Add, GroupBox, x128 y83 w157 h75, Text Replacement
Gui, Add, CheckBox, x132 y95 w150 h30 vformJdpn Checked%jdpn% gJdpn, JD Product Names
Gui, Add, CheckBox, x132 y125 w150 h30 vformGlovar Checked%glovar% gGlovar, Global Variables
Gui, Add, CheckBox, x12 y187 w100 h30 vformGer Checked%ger% gGer, DE ([ as prefix)
Gui, Add, Button, x132 y190 w150 h23 gHelp, Click here for help (v%d3k_version%)

View File

@ -1,6 +1,6 @@
#Include, func.ahk
Menu, Tray, Icon, shell32.dll, 283 ; Set the tray icon to a keyboard
SetWorkingDir, %A_MyDocuments%\D3K ; Make sure we can find the .ahks linked below
csv = %A_MyDocuments%\Work_Docs\emails.csv ; Where the email CSV is
Gui, +AlwaysOnTop +ToolWindow

View File

@ -1,4 +1,4 @@
xID,Email,Name,Demo Username
X1,test1@example.com,Person 1,User 1
X2,test2@example.com,Person 2,User 2
X3,test3@example.com,Person 3
xID,Email,Name,Demo Username,Dealer Org
X1,test1@example.com,Person 1,User 1,554866
X2,test2@example.com,Person 2,User 2,69983
X3,test3@example.com,Person 3,,4832
1 xID,Email,Name,Demo Username xID Email Name Demo Username Dealer Org
2 X1,test1@example.com,Person 1,User 1 X1 test1@example.com Person 1 User 1 554866
3 X2,test2@example.com,Person 2,User 2 X2 test2@example.com Person 2 User 2 69983
4 X3,test3@example.com,Person 3 X3 test3@example.com Person 3 4832

View File

@ -3,9 +3,9 @@ SendMode, Input
FileEncoding, UTF-8 ; Makes sure the special characters dont break stuff
SetWorkingDir, %A_MyDocuments%\D3K ; Make sure we can find the .ahks linked below
d3k_version = 2.5 ; The current version
d3k_version = 2.7 ; The current version
settini = %A_MyDocuments%\D3Ksettings.ini ; Where the settings ini is
ini = %A_MyDocuments%\D3Ksettings.ini ; Where the settings ini is
GetDateTime(lang)
{
@ -35,7 +35,7 @@ GetInfo(xID) ; Accept what is passed here as the variable "xID" in the script
if InStr(Array[1],xID) ; if at the specified element (1) the specified content (dealers xID) has been found,
Break ; stop searching
}
Test:= {xid: Array[1], email: Array[2], name: Array[3], user: Array[4]} ; Return the array so we can do {variable}.email and so on
Test:= {xid: Array[1], email: Array[2], name: Array[3], user: Array[4], org: Array[5]} ; Return the array so we can do {variable}.email and so on
Return Test
}
if !(xID)
@ -90,6 +90,7 @@ ini_writeValue(location, inKey, inValue)
needle := inKey . "=.*"
replacement := inKey . "=" . inValue
tempini := RegExReplace(tempini, needle, replacement,, 1)
tempini := RegExReplace(tempini, "\R+\R", "`r`n")
WinWaitNotActive, GloVar.ini
FileAppend, %tempini%, tempini ; Append the fixed ini to a new file
FileCopy, tempini, %location%, 1 ; Copy the file over, overwriting existing contents

View File

@ -1,15 +1,16 @@
[Serial Numbers]
1=
ch=
2=
MTG=
VIN=
[Operations Center]
usr=
org=
[Info]
case=
dus=
dnm=
dem=
[Serial Numbers]
1=
ch=
2=
MTG=
VIN=
[Operations Center]
usr=
org=
dorg=
[Info]
case=
dus=
dnm=
dem=
xID=