Solved

parse input paramaeter of a batch file

Posted on 2003-12-08
1
842 Views
Last Modified: 2008-02-01
Hi!
I get parameters in a batch file but I get them '"' (like: "AAA").
I want to strip them from the '"' if they have such.
Is there a way to do this?
Thanks!
0
Comment
Question by:rzvika2
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 5

Accepted Solution

by:
brianadkins earned 50 total points
ID: 9896104


Couple ways to do this:

Strip off first and last characters:
     set VAR=%VAR:~1,-1%

or

Replace all quotation marks with nothing:
     set VAR=%VAR:"=%

-Brian Adkins
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
robocopy for today files 14 225
Filter echo results from batch file output 7 80
move command 5 67
Recursively Delete Files 5 103
VALIDATING DATES One method of validating dates is to jam the date into the DATE command and see if it accepts it by examining the system's errorlevel value. A non-zero result indicates failure. A typical example might look something like the fol…
Being a system administrator some time we require to do things remotely, one of them is installing software. Here I am going to tell you how to install software through wmic (Windows management instrument console). I am not at all saying that this i…

726 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question