Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Dentrix G5 script to fix slow chart loads. Run this AFTER renaming/deleting C:\Program Files (x86)\Dentrix\Cust\Chart.Startup
::Make sure registry commands are not disabled or windows is damaged
reg /?
if errorlevel 1 (
GOTO SYSTEMREPAIR
)
if errorlevel 0 (
GOTO HI
)
::**********************************************************************************************
:HI
ECHO OFF
::GENERIC ITEMS not based off version, windows version etc. or need to be done for safety before anything is changed
::TITLE Eservices Esync appointment status fixer. Creates registeries and makes sure they are correct for the DXconnect ::ODBC drivers and attempts to check the servers name against the broadcast name when run on the server and alerts if they
::do not match as this causes an issue
ECHO OFF
Title Dentrix Dental Systems
::Set time stamp token for future use for renaming / backing up of files that need to be unique to prevent being overwritten
for /F "tokens=2-4 delims=/ " %%i in ('date /t') do set tdtd=%%i%%j%%k
for /F "tokens=5-8 delims=:. " %%i in ('echo.^| time ^| find "current" ') do set ttrn=%%i%%j
set UNIQUETIME=%tdtd%%ttrn%
CLS
::Make temp backup of all registries that are known to be used by Dentrix and may be affected by this utility in temp directory
CLS
ECHO OFF
CLS
@ECHO The utility will now make a backup of all relevant
@ECHO Registry Paths for Dentrix before changes are made.
@ECHO These backup files are located at
@ECHO %temp%\Dentrix Backup
Pause
MD "%temp%\Dentrix Backup"
REG EXPORT "HKEY_CURRENT_USER\Control Panel\Desktop" "%temp%\Dentrix Backup\DESKTOP%UNIQUETIME%.reg"
CLS
::********************************************************************************************
::Close all open Dentrix modules before proceeding, include a warning before continuing
ECHO OFF
CLS
@ECHO Proceeding will close all Dentrix Modules on this computer
PAUSE
tasklist /FI "IMAGENAME eq apptbook.exe" 2>NUL | find /I /N "apptbook.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im apptbook.exe /T | Echo Appointment Book found.
tasklist /FI "IMAGENAME eq appt.exe" 2>NUL | find /I /N "appt.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im appt.exe /T | Echo Appointment List found.
tasklist /FI "IMAGENAME eq office.exe" 2>NUL | find /I /N "office.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im office.exe /T | Echo | Echo Office Manager found.
tasklist /FI "IMAGENAME eq chart.exe" 2>NUL | find /I /N "chart.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im chart.exe /T | Echo Patient Chart found.
tasklist /FI "IMAGENAME eq document.center.exe" 2>NUL | find /I /N "document.center.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im document.center.exe /T | Echo Document Center found.
tasklist /FI "IMAGENAME eq dtxquicklaunch.exe" 2>NUL | find /I /N "dtxquicklaunch.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im dtxquicklaunch.exe /T | Echo Dentrx Quick Launch found.
tasklist /FI "IMAGENAME eq applauncher.exe" 2>NUL | find /I /N "applauncher.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im applauncher.exe /T | Echo Dentrix Application Launcher found.
tasklist /FI "IMAGENAME eq dxport.exe" 2>NUL | find /I /N "dxport.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im dxport.exe /T | Echo DxPort found.
tasklist /FI "IMAGENAME eq dxprint.exe" 2>NUL | find /I /N "dxprint.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im dxprint.exe /T | Echo DxPrint found.
tasklist /FI "IMAGENAME eq websyncreminder.exe" 2>NUL | find /I /N "websyncreminder.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im websyncreminder.exe /T | Echo WebSync Reminder found.
tasklist /FI "IMAGENAME eq esyncreminder.exe" 2>NUL | find /I /N "esyncreminder.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im esyncreminder.exe /T | Echo eSync Reminder found.
tasklist /FI "IMAGENAME eq famfile.exe" 2>NUL | find /I /N "famfile.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im famfile.exe /T | Echo Family File found.
tasklist /FI "IMAGENAME eq journal.exe" 2>NUL | find /I /N "journal.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im journal.exe /T | Echo Office Journal found.
tasklist /FI "IMAGENAME eq labtrack.exe" 2>NUL | find /I /N "labtrack.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im labtrack.exe /T | Echo Lab Case Manager found.
tasklist /FI "IMAGENAME eq ledger.exe" 2>NUL | find /I /N "ledger.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im ledger.exe /T | Echo Ledger found.
tasklist /FI "IMAGENAME eq pamgr.exe" 2>NUL | find /I /N "pamgr.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im pamgr.exe /T | Echo Practice Assistant Manager found.
tasklist /FI "IMAGENAME eq pracasst.exe" 2>NUL | find /I /N "pracasst.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im pracasst.exe /T | Echo Practice Assistant found.
tasklist /FI "IMAGENAME eq presenter.exe" 2>NUL | find /I /N "presenter.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im presenter.exe /T | Echo Dentrix Presenter found.
tasklist /FI "IMAGENAME eq questionnaire.exe" 2>NUL | find /I /N "questionnaire.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im questionnaire.exe /T | Echo Patient Questionnaires found.
tasklist /FI "IMAGENAME eq query.exe" 2>NUL | find /I /N "query.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im query.exe /T | Echo Query (Letter Merge) found.
tasklist /FI "IMAGENAME eq timeclock.exe" 2>NUL | find /I /N "timeclock.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im timeclock.exe /T | Echo Dentrix Time Clock found.
tasklist /FI "IMAGENAME eq totscr.exe" 2>NUL | find /I /N "totscr.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im totscr.exe /T | Echo Practice Analysis found.
tasklist /FI "IMAGENAME eq txplanner.exe" 2>NUL | find /I /N "txplanner.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im txplanner.exe /T | Echo Treatment Planner found.
tasklist /FI "IMAGENAME eq tpman.exe" 2>NUL | find /I /N "tpman.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im tpman.exe /T | Echo Treatment Manager found.
tasklist /FI "IMAGENAME eq dtxrx.exe" 2>NUL | find /I /N "dtxrx.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im dtxrx.exe /T | Echo Dentrix Prescriptions found.
tasklist /FI "IMAGENAME eq histview.exe" 2>NUL | find /I /N "histview.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im histview.exe /T | Echo History Viewer found.
tasklist /FI "IMAGENAME eq patpict.exe" 2>NUL | find /I /N "patpict.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im patpict.exe /T | Echo Patient Picture found.
tasklist /FI "IMAGENAME eq perio.exe" 2>NUL | find /I /N "perio.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im perio.exe /T | Echo Perio found.
tasklist /FI "IMAGENAME eq trojan.exe" 2>NUL | find /I /N "trojan.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im trojan.exe /T | Echo Dentrix Trojan Viewer found.
tasklist /FI "IMAGENAME eq practiceadvisor.exe" 2>NUL | find /I /N "practiceadvisor.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im practiceadvisor.exe /T | Echo Practice Advisor found.
tasklist /FI "IMAGENAME eq searchpayments.exe" 2>NUL | find /I /N "searchpayments.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im searchpayments.exe /T | Echo Search Payments found.
tasklist /FI "IMAGENAME eq checkupdates.exe" 2>NUL | find /I /N "checkupdates.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im checkupdates.exe /T | Echo Check for Updates found.
tasklist /FI "IMAGENAME eq ep.exe" 2>NUL | find /I /N "ep.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im ep.exe /T | Echo Edit Path found.
tasklist /FI "IMAGENAME eq _HistEdit.exe" 2>NUL | find /I /N "_HistEdit.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im _HistEdit.exe /T | Echo History Edit found.
tasklist /FI "IMAGENAME eq DentReg.exe" 2>NUL | find /I /N "DentReg.exe">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /im DentReg.exe /T | Echo Dentrix Configuration Editor found.
tasklist /FI "IMAGENAME eq HSPS*" 2>NUL | find /I /N "HSPS*">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /fi "IMAGENAME eq HSPS*" /im * /T | Echo HSPS Digital Highway services found.
tasklist /FI "IMAGENAME eq Guru*" 2>NUL | find /I /N "Guru*">NUL
if "%ERRORLEVEL%"=="0" taskkill /f /fi "IMAGENAME eq Guru*" /im * /T | Echo HSPS Guru found.
cls
::END of Generic Section
FOR /F "tokens=2* delims= " %%A IN ('REG QUERY "HKEY_CURRENT_USER\Control Panel\Desktop" /v "ForegroundLockTimeout"') DO SET COUNTRYCODE=%%B
IF %COUNTRYCODE% == 0x0 (GOTO NOFIX)
:FIX
cls
REG DELETE "HKEY_CURRENT_USER\Control Panel\Desktop" /v "ForegroundLockTimeout" /f
cls
reg add "HKEY_CURRENT_USER\Control Panel\Desktop" /v "ForegroundLockTimeout" /t "Reg_DWord" /d 0x0
cls
FOR /F "tokens=2* delims= " %%A IN ('REG QUERY "HKEY_CURRENT_USER\Control Panel\Desktop" /v "ForegroundLockTimeout"') DO SET COUNTRYCODE=%%B
IF %COUNTRYCODE% == 0x0 (GOTO CORRECT)
cls
@ECHO Unable to update timeout %COUNTRYCODE%
@ECHO please contact support
pause
exit
:CORRECT
cls
@ECHO Timeout Succesfully Corrected
@ECHO A reboot is required for changes to take effect
pause
exit
:NOFIX
cls
@ECHO Timeout is already correct
pause
exit
::START SYSTEM CMD ERROR HANDELING
:SYSTEMREPAIR
@ECHO THe utility has found that the windows system
@ECHO has an issue that prevents it from working
@ECHO and will cause issues in Dentrix.
@ECHO please contact a hardware technician
@ECHO regarding command prompt not allowing
@ECHO registry querys to be run
PAUSE
EXIT
::END SYSTEM CMD ERROR HANDELING
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment