If you've ever tried to run custom scripting or batch files in a
network shared folder that isn't mapped to a letter drive in Windows
you may have encountered an issue where the command prompt just closes immediately and your command never goes through.
I struggled with this for a while and never really immediately found out a reason why it happened but for my workflow using
network or using drive letter mappings
wasn't an option while I
finally found the solution and I'm gonna share it to share it with you rather not to you. I guess it's to you
Right after this: Tubebuddy is the best tool you can get to manage your YouTube channel
You can update videos in bulk, optimize your SEO
Syndicate to social media, backup your metadata and more all with a simple browser extension! Head to eposvox.com/tubebuddy
to learn more and download it for free
This is a little bit of a niche
recommendation or problem to solve but I've been working on my efficiency and I wanted to make a
batch file that I can then assign to a button on my stream deck or a right-click context menu item that
makes a bunch of folders for me.
I'll show you the code real quick super basic squid script literally "mkdir"
directory or MD and then a bunch folders in
In theory it should work, but when I try to run it in my video project folders
nothing happens and that's really bizarre.
I've seen video evidence of this command working. This is how it works.
I'm not a programmer, but I at least have the basic understandings and I solve videos with it as well
however, if I make a folder on my desktop and put the batch file in there and then run it
it works fine. There's a little bit of a refresh delay, but it works
So why the heck won't it work on my project files?
Well, it's because the way that I have all of my network drives map is by host name.
It is a network map-like file location mapping not a mapped Drive letter. Now
I do have network map drive letters because I wish to
monitor, how much space is available in certain applications require Drive letters
But I avoid using them when at all possible for my project files
because if I import footage and make the project files with a drive letter
then when I open them up on another computer the drive letters won't be there or they'll be mapped differently or any kind of situation
and the entire project will need real inking in. It's just a nightmare
Where as if I have everything on a centralized Network storage, it works fine. I
have spent half an hour digging through Stack Overflow and forum posts trying to figure out why a lot of them recommend disabling some
security things in the registry and a lot of stuff that honestly shouldn't be done and then finally like half an hour later I finally
found this one little command who add to the start of the batch file
which temporarily maps the directory you're in to a
route to like an actual drive and then the batch run because otherwise as you see
it just closes automatically and it gives some error about not having a UNC path. This is by design Windows
does this on purpose so that if if you have UAC or user access control enabled you can't
you know infect other computers if you're a virus basically, which is pretty smart.
The way you have to do is edit your batch file here, which I have already open
But I'm using notepad++
and just add this command push D space parentheses squiggly dp0 on yes. I call it squiggly
I know get over.
I'll just paste that in there at the start of your script. It's safe and then when you rerun it
like magic and a couple seconds of delay of Windows Explorer it's really slow refresh we have files.
Well, this is the first step of a future project, but I just figured this out we wanted to share with you and
that's it. Hope you enjoyed hit the like button, if you did get subscribed for more awesome tech content and usually more accessible stuff
I realize this is super niche, but if you've ever had issues getting batch files to run on network shares
this might be your fix. Check us out on patreon at patreon.com/eposvox to contribute to free tech education such as this
And I'll see you in the next video!