Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a problem: I want to get the filename only from this path line in Command Prompt

Here's my path:

\\jktfile-01\lsmk\SRP\BankPelapor\201209\Instance\2882000-2012-09-30-BSMS26.xml

What kind of command should I do?

I already tried this solution How to get filename only without path in windows command line?

but it didn't work...

share|improve this question
2  
Please describe exactly what you tried. – Scott Mar 14 '13 at 4:54
up vote 1 down vote accepted

Dir /b \\jktfile-01\lsmk\SRP\BankPelapor\201209\Instance\*.xml

will output

2882000-2012-09-30-BSMS26.xml

along with all other .xml files.

Not 100% sure what you are asking for though.

share|improve this answer
    
I believe the OP is looking for dir /b \\jktfile-01\lsmk\SRP\BankPelapor\201209\Instance\2882000-2012-09-30-BSMS26.xml, which will output just 2882000-2012-09-30-BSMS26.xml. – Scott Mar 14 '13 at 5:53
    
@Scott Yep i want to get the file name from the line of link that i got, thx – Sabilv Mar 14 '13 at 7:18

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .