batch file fails after upgrade to v2004

Page 2 of 3 FirstFirst 123 LastLast

  1. Posts : 7,484
    Windows 10 Home 20H2
       #11

    Sebastian42 said:
    Having the CMD window NOT show is even more attractive, but VBS daunts me even more than what you had already proposed.
    Click here to download "Empty_Recycle_Bin.vbs".

    Just double-click to run it, which will empty Recycle Bin without a window.
    No third-party application is needed.

    Bree said:
    You'll still see it appear briefly on the taskbar

    You will not see anything appear after running the attached VBScript file. Try it out.
    batch file fails after upgrade to v2004 Attached Files
      My Computer


  2. Posts : 278
    Win10 32bit v20H2
    Thread Starter
       #12

    I have created the CMD file where it is needed, and it does in fact do the job, but seems to be the very last item at StartUp, and the CMD window displays for a very long time before autodisappearing. This is happening on a 2.2GHz laptop with 4Gb of RAM of which only 2.9Gb is seen.
      My Computer


  3. Posts : 16,144
    Win 10 Pro 64-bit v1909 - Build 18363 Custom ISO Install
       #13

    Did you see @Matthew Wai's post above yours?
      My Computer


  4. Posts : 7,484
    Windows 10 Home 20H2
       #14

    Sebastian42 said:
    the CMD window displays for a very long time before autodisappearing.
    Try my VBScript, which will not bring up a window.
      My Computer


  5. Posts : 278
    Win10 32bit v20H2
    Thread Starter
       #15

    Mathew - I have just tried your VBS here on this PC (not where it was needed) and indeed it works without displaying THAT window, if double clicked. I have TWO reservations about it 1. It first asks if really mean it; and 2. I want it to autorun at Startup without having to double click it.
      My Computer


  6. Posts : 7,484
    Windows 10 Home 20H2
       #16

    Sebastian42 said:
    1. It first asks if really mean it
    Please post a screenshot showing what it asks.
    My VBScript file should not ask anything. Does "It" refer to your CMD script or my VBScript?


    Sebastian42 said:
    2. I want it to autorun at Startup without having to double click it.
    Put it into C:\ProgramData\Microsoft\Windows\Start Menu\Programs\StartUp
      My Computer


  7. Posts : 278
    Win10 32bit v20H2
    Thread Starter
       #17

    "Do you REALLY mean it" (paraphrased) occurs on THIS 3.5GHz/4Gb PC where the original nircmd batch file still works;
    but on the 2.2GHz 3Gb laptop where it stopped working, your VBS works PERFECTLY - from the StartUp folder.
    Thank you all for your various contributions and for dragging me into the 21st century.
      My Computer


  8. Posts : 7,484
    Windows 10 Home 20H2
       #18

    Sebastian42 said:
    your VBS works PERFECTLY
    It is not perfect. It is overly complicated. The following version is much simpler and contains only one line of command.
    batch file fails after upgrade to v2004 Attached Files
      My Computer


  9. Posts : 278
    Win10 32bit v20H2
    Thread Starter
       #19

    Even better - thank you
    I suspect your time is around 6.15pm - mine is 3.15am, so I will not be trying that before going to bed.

    - - - Updated - - -

    Sad to say your VBS held up all the autostarts until I had interacted with the dialog it triggered.batch file fails after upgrade to v2004-vbs-querry.jpg
      My Computer


  10. Posts : 7,484
    Windows 10 Home 20H2
       #20

    Uncheck the box beside "Always ask before opening this file". If it does not work, use Task Scheduler to run it. I have never seen such a dialog box while using a VBScript file.

    I could not reproduce your problem at my end. I put the VBScript file in the same directory and double-click on it, which then ran silently in the background.

    batch file fails after upgrade to v2004-vbs.jpg
      My Computer


 

  Related Discussions
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd
All times are GMT -5. The time now is 19:27.
Find Us




Windows 10 Forums