sitestrong

    Run Vbs File From Cmd Peru

    4/28/2019/ Comments off

    I am new to scripting ,vbs and HTA commands but I have tryed to create a simple hta folder with some text boxes that represent a date and the current time and I need to run a specific cmd command that takes that date/hour and use them in the specified commad.I think you will understand more when you read the code.I appologise in advance for the mistakes.

    Hey, thanks for the rapid responses.I have managed to get it to run a part of what i want.The part of settime.sh was actually a command in putty and i didn't quite realise it at the moment of writing but i have managet to get it to a point where it runs putty when I press the run button.Now I need it to type in the command with the values given by the user in the text boxes.This is what I have so far: HTA Test

    Gabriel M.
    Gabriel M.Gabriel M.

    1 Answer

    I see several mistakes in the above statement:

    • There's a spurious WScript.
    • CMD.EXE doesn't have an option /g. Did you mean /c?
    • .sh is an extension typically used for Linux/Unix shell scripts. Windows batch files have the extension .bat or .cmd.
    • VBScript doesn't expand variables inside strings, so you need to concatenate your variables with the string literals.

    Also, I'd append , 0, True to the statement, so that the CMD instance runs hidden and the code waits for the external command to complete.

    Try this:

    Ansgar WiechersAnsgar Wiechers

    Not the answer you're looking for? Browse other questions tagged vbscriptscriptingcmdhta or ask your own question.

    I need to run a command to copy a file from one location to another through Command Prompt using a vbs file. this is what I have however it keeps throwing an error at me.

    The error i get is:

    Source: Microsoft VBScript compilation error'

    Please help :)

    user1590368user1590368

    2 Answers

    The problem is on this line:

    Your first quote next to 'S:Claims' ends the string; you need to escape the quotes around your files with a second quote, like this:

    You also have a typo in S:ClaimsSound.wav, should be S:ClaimsSound.wav.

    I also assume the apostrophe before Dim oShell and after Set oShell = Nothing are typos as well.

    LittleBobbyTablesLittleBobbyTables
    Shahriar KhazaeiShahriar Khazaei

    Not the answer you're looking for? Browse other questions tagged vbscriptcommand-prompt or ask your own question.

    Post navigation

    Navigation

    Android Emulator For Windows 7 32 Bit 1Gb Ram Free Download
    Tu Na Jaane Aas Paas Hai Khuda Instrumental Mp3 Download

    Most Viewed Pages

    • Principle Of Management In Hindi Pdf
    • Jelly Bean Systemui Apk Download
    • Scott Pilgrim Vs The World Game Download Code
    • El Clon Full Episodes Download
    • Airwolf Season 1 Episode 1 Torrent Download
    • Sap Crystal Reports 2011 Sp2 Serial
    • Chandu Name Wallpaper Download
    • Atif Aslam Song Pehli Nazar Mein Slow Version Download
    • Learn English Through Tamil Pdf Books Free Download
    • Thomas Trainz Downloads Free
    • Download Game Pc Bus Simulator Versi Indonesia Free
    • Chadta Suraj Dhire Dhire Mp3 Song Free Download
    • Stan Walters The Truth About Lying Pdf Viewer
    • Chedlya Tara Chedlya Bhavna Ringtone Download
    • Vray Cracked
    • Lectra Diamino Fashion Crack Download
    • Hardware Id Trivium Keygen Generator
    • Old Malayalam Movie Songs Free Download 123musiq
    • Free Download Autocad 2010 Portable 32 Bit Windows 7
    • Download Game The Sims 4 Highly Compressed
    • Aoc-hrr 2nd Edition Test
    • Mere Brother Ki Dulhan Full Movie Download Mkv
    • Free Download Hebrew Font Microsoft Word
    • Aquachem Software Free Download
    • Yeh Tera Ghar Yeh Mera Ghar Full Movie Download
    sitestrong