r/BatchScripts • • Sep 27 '20

Why does it not open?

Thumbnail
docs.google.com
1 Upvotes

r/BatchScripts • • Sep 18 '20

A batch script that grabs certain files sizes and moves into vidcoder

1 Upvotes

I'm looking for some help with batch script. What I would like to do is have a batch script scan my hard drive video files and only grab video files over a certain size and move them to my vidcoder to be compressed. Is that something that can be done?. Any help would be greatly appreciated 🙏.


r/BatchScripts • • Aug 26 '20

Set Exit code 259 as success

1 Upvotes

I'm pretty new to Batch scripting. Please help me with the below syntax.

My aims is to set exit code 0 as success when exit code is 259.

if "%ERRORLEVEL%"=="259"{

SET intRC= 0

EXIT %intRC%

Echo "Success"}

else{

EXIT %ERRORLEVEL%

}


r/BatchScripts • • Jul 04 '20

Help with a batch to copy and rename recursively, files are pictures of different resolution

1 Upvotes

Hello, I made this batch COPY -r ic_launcher.png ic_launcher_round.png

and it works inside a folder, but i have other folders named mipmap-hdpi, mipmap-mdpi, mipmap-xhdpi, mipmap-xxhdpi, mipmap-xxxhdpi

So i want to put my bat in root, and order it to work in these folders doing that command, can someone help me? I'm not an expert. thanks


r/BatchScripts • • May 01 '20

Need help on delete file in C: Drive. ExamplePC123.exe. Need example scripts to delete exe.

1 Upvotes

I wanted to create a batch file. Cmd: psexec \exmaplepc123 cmd Delete from cmd. Any advice? Thanks


r/BatchScripts • • Apr 18 '20

Set focus on specific Chrome instance

1 Upvotes

I want to make a script to use on one of my shortcut keys on my keyboard, and I want it to set focus on the Chrome instance that is playing a video on youtube.

I have tried (new ActiveXObject("WScript.Shell")).AppActivate("Chrome");, but afaik I cannot specify which Chrome instance to focus.

Does anyone know if this is possible?


r/BatchScripts • • Apr 15 '20

Looking for someone to make a program. Simple?

1 Upvotes

Hey Everyone, I was curious if there was a way to make a program where there is 2 inputs.

  1. Input for starting number

  2. Input for delay
    Basically there is a discord I'm in that has a count channel. This channel is where people type in the next sequential number. There is a small cooldown which is what the delay would be for. I just want to get the count super high. Maybe it wouldn't even need to count sequentially, because the server description says what the next number is and updates every 7 seconds or so. So maybe is there a way to detect what the next number is from the program detecting the number in a certain section of my screen? After detecting it, it waits a few seconds and then types said number and sends it?
    Please let me know if any of you have any ideas, thanks!


r/BatchScripts • • Mar 13 '20

Trim data from File in batch

1 Upvotes

Hi All,

I am trying to create a script which will take below input file.

<subsession>

This is actual test which should print

</subsession>

<subsession>

This is a random Text1

</subsession>

<subsession>

This is a random Text2

</subsession>

<subsession>

This is a random Text3

</subsession>

And Should give output as below:

<subsession>

This is acutual test which shoud print

</subsession>

This means the output should contain the value from 1 iteration on <subsession> till </subsession>. and should not print the later iteration on this search String. Can anyone please help how to get this resolved.


r/BatchScripts • • Oct 05 '19

Project

1 Upvotes

Looking for some help with a school project. I need to run a batch script from an external drive that will copy all picture files from the standalone computer to the external drive it was run from.

I am new to this so anything you can show me is appreciated!


r/BatchScripts • • May 31 '19

Batch to connect to wifi

1 Upvotes

I was wondering if someone could help me with a command, employees in our office work out of multiple sites throughout the day, sometimes after going to a different site and connecting to their wifi won't let them connect to our intranet or network drives, this is currently solved by them opening command prompt and entering the following:

netsh wlan disconnect && timeout 10 && netsh wlan connect name=

After name they have to find the SSID of the wifi and enter that then run the command, this works but is difficult for a lot of people. I was wondering if we could put this into a batch file to run the command and if there's some way to get it to detect the SSID and input it in the command automatically?

Thanks for any help


r/BatchScripts • • Oct 12 '17

How do you use a loop command through the MOS window rather than notepad?

1 Upvotes

How would I type a code like this:

@echo off :start echo hi goto start

But directly to the command line rather than to notepad


r/BatchScripts • • Sep 03 '17

Mounting remote drives on Windows 7 using "Fast Boot" at startup.

1 Upvotes

This script was found elsewhere and will connect to your remotely mapped drives that Windows 7 has a problem with when Fast Boot is enabled. Change the drive letters for your own.

I have to use this on a secondary machine I have Plex on. It means I don't have to go in and click on each drive to activate it. Hope it's helpful to someone.

timeout 5
explorer X:
explorer Y:
explorer Z:
timeout 3 
taskkill /im explorer.exe
taskkill /im explorer.exe
taskkill /im explorer.exe
exit    

r/BatchScripts • • Apr 30 '17

Changing audio device in windows

1 Upvotes

So I have a random request.

I'm looking to be able to quickly switch between two audio devices in Windows 10 without having to Sound Settings and change the default playback device.

Any help would be appreciated.


r/BatchScripts • • Aug 04 '22

Batch script to clear DNS Cache

0 Upvotes

HI,

How to clear DNS Cache (Windows 10 - 64bit) by batch file. The batch file should be self elevated to run, without UAC prompt.

Thanks

KSK