in Education by
I'm running a FOR loop to retrieve the (absolute) path name for ALL *.properties file in the root folder: "C:\ExecutionSDKTest_10.2.2\". Now, I'm trying to slice the path name to only result in the file name. e.g. if absolute path is "C\ExecutionSDKTest_10.2.2\Test-101" I only want the "Test-101" part (w/out the quotes of course) I have: FOR %%G IN (C:\ExecutionSDKTest_10.2.2\*.properties) DO ( REM Ignore "C:\ExecutionSDKTest_10.2.2\" ?? java -jar %1 %G:> Logs\%%G.log ) So the absolute file path name is stored in G, but I'd only like the file name. How can I achieve this goal? JavaScript questions and answers, JavaScript questions pdf, JavaScript question bank, JavaScript questions and answers pdf, mcq on JavaScript pdf, JavaScript questions and solutions, JavaScript mcq Test , Interview JavaScript questions, JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)

1 Answer

0 votes
by
You can use %%~nG to get just the filename, or %%~nxG if you want the filename and extension.

Related questions

0 votes
    I know when Cygwin installs there is a batch file that is used to launch it in Windows. But if I ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Jul 20, 2022 in Education by JackTerrance
0 votes
    I am trying to retrieve a particular file from multiple FTP servers. those server details are stored in ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Jun 18, 2022 in Education by JackTerrance
0 votes
    I am trying to understand why the first line of my batch file fails to execute. My code is as ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Jun 2, 2022 in Education by JackTerrance
0 votes
    I am trying to understand why the first line of my batch file fails to execute. My code is as ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked May 8, 2022 in Education by JackTerrance
0 votes
    I am trying to understand why the first line of my batch file fails to execute. My code is as ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked May 7, 2022 in Education by JackTerrance
0 votes
    I am trying to understand why the first line of my batch file fails to execute. My code is as ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Apr 26, 2022 in Education by JackTerrance
0 votes
    I want to execute a certain batch file and redirect its console output to a text control in visual c ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Mar 17, 2022 in Education by JackTerrance
0 votes
    I want to execute a certain batch file and redirect its console output to a text control in visual c ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Mar 17, 2022 in Education by JackTerrance
0 votes
    I'm currently looking at ways to allow people to select multiple files at once to batch upload images. ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Mar 11, 2022 in Education by JackTerrance
0 votes
    I am developing a web page code, which fetches dynamically the content from the server and then places this ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Mar 27, 2022 in Education by JackTerrance
0 votes
    Computers manipulate data in many ways, and this manipulation is called- (A) upgrading (B) processing (C) batching ... ) None of these Select the correct answer from above options...
asked Dec 2, 2021 in Education by JackTerrance
0 votes
    The Cookie manipulation is done using which property? (a) cookie (b) cookies (c) manipulate (d) ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Oct 23, 2021 in Education by JackTerrance
0 votes
    I am new to python and cloud vision.I need to label ~20k images.My code although does the work, ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked May 7, 2022 in Education by JackTerrance
...