to run .exe ,.vbs ,.bat files on remote machines

Welcome Forums General PowerShell Q&A to run .exe ,.vbs ,.bat files on remote machines

This topic contains 3 replies, has 3 voices, and was last updated by

 
Participant
3 years, 3 months ago.

  • Author
    Posts
  • #33197

    Participant
    Points: 0
    Rank: Member

    hi all,

    i required your help in letting me know ,does valid authentication required to run any .exe ,.vbs or .bat files on remote machines.

    am a administrator in my organisation where i my id of part of administrative group in all the domain computers but still i am unable to run any of these files , help me out please .

    here is the cmdlet am using

    invoke-command -scriptblock { cscript "c:\myscript\script.vbs /act} -computername $computer

    this comes up with zero errors but can see .vbs file is not executing on remote machine.

    i request you to share the proper cmdlet to run all of these files on remote machine.

  • #33202

    Participant
    Points: -17
    Rank: Member

    Just wondering – should the script block be { cscript.exe "c:\myscript\script.vbs /act}

  • #33218

    Participant
    Points: 0
    Rank: Member

    hi andrew -even this is not working

    help me in sharing cmdlet to run bat file on remote machines .

  • #33232

    Participant
    Points: 0
    Rank: Member

    I am noticing that the scriptblock does not have a closed quote. it has an open quote but it is not closed. { cscript "c:\myscript\script.vbs /act} should it be { cscript "c:\myscript\script.vbs /act"} ?

    I may be wrong but I have been tripped up by the most trivial things.

The topic ‘to run .exe ,.vbs ,.bat files on remote machines’ is closed to new replies.

denizli escort samsun escort muğla escort ataşehir escort kuşadası escort