Kuan's Blog

There is always a better solution....

  • Home
  • Blog
    • family
      • Journey of Love (QiaoEn)
      • Journey of Love (ChengYu)
    • life
    • tech
  • About me

Email Subscribe

Want to keep up to date with my Blogs?
Loading

Recent Posts

  • Eastern View Lorne Day Trip - JUL 21
  • Warrnambool & Mt Gambier JAN 2021
  • Happy & Milky
  • Apollo Bay - JUL 2020
  • Use powershell to ping and output to log file
  • Launch another process with Encrypted Credential (Powershell)
  • 一組可愛的照片

Tags

AD Apache Apple Caching Batch bios Buller ChengYu Chrome Cisco CMD Commands Diskpart Dism Domain Controller encrypted Hospital HP idea Kluger linux Locked out Mac Melbourne Milky&Happy OSX ping Powershell Proxy QiaoEn QiaoEn; ChengYu Remote Desktop script scripting SecureString Squid SSL Switch Terminal TMG Travelling Ubuntu Windows Windows 10 Windows Server xml

Archives

Tags

AD Apache Apple Caching Batch bios Buller ChengYu Chrome Cisco CMD Commands Diskpart Dism Domain Controller encrypted Hospital HP idea Kluger linux Locked out Mac Melbourne Milky&Happy OSX ping Powershell Proxy QiaoEn QiaoEn; ChengYu Remote Desktop script scripting SecureString Squid SSL Switch Terminal TMG Travelling Ubuntu Windows Windows 10 Windows Server xml

Recent Posts

  • Eastern View Lorne Day Trip - JUL 21
  • Warrnambool & Mt Gambier JAN 2021
  • Happy & Milky
  • Apollo Bay - JUL 2020
  • Use powershell to ping and output to log file
Skip to content

Kuan's Blog

Tag: Batch

Get Parent Folder by Batch

To get folder from 1 level up:


@echo off
SET CurrentDirectory=%~dp0
echo %CurrentDirectory%

for %%B in (%CurrentDirectory%.) do set ParentFolder=%%~dpB
echo %ParentFolder%
Posted on December 11, 2017December 11, 2017 by kuan
Proudly powered by WordPress ~ Theme: Scrawl by WordPress.com.