@echo off REM gocmm-debug.bat - launcher for gocmm-debug.ps1 REM REM *** RUN THIS AS THE OPERATOR (the locked-down shop-floor user). *** REM *** DO NOT right-click "Run as administrator" - that hides the bug. *** REM REM Diagnoses goCMM startup failures: REM 1. "Requested registry access is not allowed" - dumps the goCMM key ACL REM to confirm lockdown stripped the BUILTIN\Users write grant (PROBE 1-2). REM 2. "Object reference not set to an instance of an object" at start: REM - PROBE 3: part-group match (reg vs ApplicationSettings.xml, case-sensitive). REM - PROBE 4: pulls the actual .NET crash stack from the Application log. REM - PROBE 5: part-group UNC reachability + PC-DMIS COM registration. REM Confirmed root cause to date: PC-DMIS COM server NOT registered -> REM goCMM's Activator.CreateInstance gets a null type -> NRE. Fix: run REM Pcdlrn.exe once elevated (/regserver). PROBE 5 reports this directly. REM Output lands in C:\Logs\CMM\. setlocal set "HERE=%~dp0" echo. echo Running goCMM debug as %USERDOMAIN%\%USERNAME% ... echo (If you see "Administrator: ..." in this window title, STOP - run as the operator instead.) echo. powershell.exe -NoProfile -ExecutionPolicy Bypass -File "%HERE%gocmm-debug.ps1" echo. echo --------------------------------------------------------------- echo Done. Collect everything under C:\Logs\CMM\ (the .txt and .reg). echo --------------------------------------------------------------- pause