locked
script will not update the password RRS feed

  • Question

  • I am writing a script to deploy the automated bios upgrade the script runs fine until the point where it requires a password I have placed a statement in the script to add the password "REM if %script%== Biospassword goto main". The problem is that prompt for the password appears but it will not enter the password and continue with the installation. Help!

    IF NOT EXIST C:\STAGING\T410 Bios update utility NUL MD C:\T410 Bios update utility
    IF NOT EXIST C:\STAGING\T410 Bios update utility MD C:\staging\T410 Bios update utility

    @ECHO OFF
    @echo ****************** Start of T410 Bios update utility Installation ********************** >> C:\Staging\T410 Bios update utility\Install.log
    @echo
    @echo


    cd /d%~dp0
    WINUPTP.EXE -s 
    REM @echo off 
    REM:password 
    REM set /p script=~ 
    REM if %script%== Biospassword goto main 
    REM goto fail 

    REM 6uuj20us.exe -s

    @echo Error level code: %ERRORLEVEL% C:\Staging\T410 Bios update utility\Install.log
    @echo . Done! >> C:\Staging\T410 Bios update utility\Install.log


    exit %ERRORLEVEL%


    Wednesday, April 30, 2014 9:14 PM

Answers

  • It looks like the posted script was cobbled together using a combination of guesswork and copy-and-paste. Neither technique is going to produce a working result.


    -- Bill Stewart [Bill_Stewart]

    • Marked as answer by Bill_Stewart Tuesday, June 17, 2014 6:02 PM
    Thursday, May 1, 2014 7:16 PM

All replies

  • Your post is very confusing.

    The REM statement in a shell script (batch file) is a comment line.

    In other words, all those lines that start with REM don't do anything at all. They're just comments.


    -- Bill Stewart [Bill_Stewart]

    Wednesday, April 30, 2014 9:47 PM
  • You cannot enter a BIOs or file password from a file.

    ¯\_(ツ)_/¯

    Wednesday, April 30, 2014 10:03 PM
  • It looks like the posted script was cobbled together using a combination of guesswork and copy-and-paste. Neither technique is going to produce a working result.


    -- Bill Stewart [Bill_Stewart]

    • Marked as answer by Bill_Stewart Tuesday, June 17, 2014 6:02 PM
    Thursday, May 1, 2014 7:16 PM