problem saving .bat file

Page 1 of 3 123 LastLast

  1. Posts : 133
    win 10
       #1

    problem saving .bat file


    In Win 10, want to save .bat file in a Program directory. Downloaded a program in a zip file and unzipped it to a Program Files (x86) folder. This folder has other .bat files but one was missing. Now have it but cannot save it in the folder.
    I am the owner of the folder.
      My Computer


  2. Posts : 42,734
    Win 10 Pro (22H2) (2nd PC is 22H2)
       #2

    Hi, I don't know why you can't access it- you haven't quoted the message I guess you've seen.

    One way you can certainly do this is to SHIFT click restart and navigate to a command prompt, and (cautiously, making sure you are doing what you intend) copy your file into that folder.

    As Windows isn't running, permissions problems won't apply.

    If not familiar with the command prompt, get a copy of Kyhi's boot DVD /flash drive from the top of the Software and Apps section here, boot from that to what looks like Windows, and thus copy your file.
      My Computers


  3. Posts : 2,832
    Windows 10 Pro X64
       #3

    Hi,

    I am the owner of the folder.
    Maybe but do you have "Write" permissions ?

    Cheers,
      My Computers


  4. Posts : 268
    Windows 10 Pro x64 v22H2
       #4

    Yea. is a security / permissions thing.

    I know it's a pain but save the .bat file to Desktop then drag and drop to Program Files. Then you'll be prompted for admin permission. Click yes.
      My Computer


  5. Posts : 9,765
    Mac OS Catalina
       #5

    ComputerGeek said:
    Yea. is a security / permissions thing.

    I know it's a pain but save the .bat file to Desktop then drag and drop to Program Files. Then you'll be prompted for admin permission. Click yes.
    There is no security/permissions bug. We no longer use batch files with Windows. You use a script to run what you ned if it is for anything in particular.

    Batch files were needed during DOS days. They will no longer work in how people think that they would when it comes to the newer Windows.
      My Computer


  6. Posts : 2,832
    Windows 10 Pro X64
       #6

    Hi,

    We no longer use batch files with Windows
    Who are "we" ?
    .bat is just a file extension that stems from the DOS era but you can still use it in W10 if the command lines are properly written for the W10 command line interpreter.

    Cheers,
      My Computers


  7. Posts : 133
    win 10
    Thread Starter
       #7

    dalchina said:
    Hi, I don't know why you can't access it- you haven't quoted the message I guess you've seen.

    One way you can certainly do this is to SHIFT click restart and navigate to a command prompt, and (cautiously, making sure you are doing what you intend) copy your file into that folder.

    As Windows isn't running, permissions problems won't apply.

    If not familiar with the command prompt, get a copy of Kyhi's boot DVD /flash drive from the top of the Software and Apps section here, boot from that to what looks like Windows, and thus copy your file.
    After the folder was renamed the ownership changed. After fixing was able to save. Thank you.
      My Computer


  8. Posts : 13,896
    Win10 Version 22H2 Pro and Home, Win11 Pro and Home
       #8

    I still use a few .bat/batch files to accomplish something in Win10 so they are not actually dead. One example is for flushing the DNS and the other is for removing OneDrive, both on my Desktop and don't need to open Command Prompt first, just double-click. The biggest difference I see between Win10 Command Prompt and older versions is some of the DOS-type commands are either missing or not functional. A lot of the commands here still work even though the page mentions WinXP:
    Command-line reference A-Z
      My Computers


  9. Posts : 9,765
    Mac OS Catalina
       #9

    fdegrove said:
    Hi,
    Who are "we" ?
    .bat is just a file extension that stems from the DOS era but you can still use it in W10 if the command lines are properly written for the W10 command line interpreter.
    That would be everyone that works with Windows to have it perform certain functions. A Script is a lot safer than a batch file. Also Scripts allow you to do a lot more than a batch file. There is no Command Line Interpreter any more. Powershell is taking its place, Command is going away because it is also outdated and a holdover from the old days.

    Those that still want to use batch files are holdovers from the DOS days. Again no one uses them anymore since it is a outdated method. Break Your Batch Habit and Move to PowerShell | PowerShell content from Windows IT Pro
      My Computer


  10. Posts : 419
    Win 7 Pro/32, Win 10 Pro/64/32
       #10

    Bull Bro!

    Buried deep within Windows, is DOS. That simply means "Disk Operating System".
    Windows won't work, without one.
    It's been right there since the first version of Windows hit the market.

    Regardless of the version of Windows, they all will run Batch Files. I have several that I use every day,
    to do disk cleanup, backup data files, and perform other repetitive jobs.

    When I set up a new version of Windows, I use many batch files to install things into Windows and
    tweak it and tune it for maximum efficiency. Batch files are just a list of DOS commands and require
    very little knowledge or training. On the other hand learning the Scripting language is beyond the
    capability or interest of most users.
    I've been a PC tech since 1980 and I still don't know how to write 'Scripts'. And at 73 I'm probably
    too old to learn it now. :)

    I write batch files in Wordpad, then save them with the extension set to .bat and the file type set to "All Files".
    If a batch file gets saved with the .txt extension, that can be renamed to .bat easily.

    Cheers Mates,
    TechnoMage
      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 16:20.
Find Us




Windows 10 Forums