@echo off
REM 获取当前批处理文件所在目录
set "SCRIPT_DIR=%~dp0"
REM 查找当前目录下与批处理文件同名的.exe文件（不包括扩展名）
set "SETUP_EXE=%SCRIPT_DIR%DASCOM_DC8600_Windows-Driver-V2.135.0.0.exe"

REM echo Searching for setup executable: %SETUP_EXE%

if exist "%SETUP_EXE%" (
    REM echo Found setup executable, starting uninstall only...
    start /wait "" "%SETUP_EXE%" /UNINSTALLONLY /VERYSILENT
    REM echo Uninstall process completed.
) else (
    REM echo Error: Setup executable not found.
    pause
)