MS-DOS

Moderators: blip
Number of threads: 389
Number of posts: 904

This Forum Only
Post New Thread
Single Post View       Linear View       Threaded View      f

Report
Re: unable to set variable in DOS batch file Posted by anthrax11 on 23 Aug 2009 at 6:01 AM
Use percent signs to refer to variables and don't put spaces next to the equal sign:
set MPATH=%MYSQL_PATH%

Then you can use echo "%MPATH%" or echo %MPATH% to print it.
Thread Tree
nirvan unable to set variable in DOS batch file on 22 Aug 2009 at 3:11 PM
anthrax11 Re: unable to set variable in DOS batch file on 23 Aug 2009 at 6:01 AM
nirvan Re: unable to set variable in DOS batch file on 23 Aug 2009 at 9:38 PM
nirvan Re: unable to set variable in DOS batch file on 23 Aug 2009 at 9:39 PM
anthrax11 Re: unable to set variable in DOS batch file on 24 Aug 2009 at 2:24 AM
nirvan Re: unable to set variable in DOS batch file on 25 Aug 2009 at 1:59 AM
anthrax11 Re: unable to set variable in DOS batch file on 25 Aug 2009 at 2:41 AM
nirvan Re: unable to set variable in DOS batch file on 25 Aug 2009 at 6:50 AM



 

Recent Jobs

Official Programmer's Heaven Blogs
Web Hosting | Browser and Social Games | Gadgets

Popular resources on Programmersheaven.com
Assembly | Basic | C | C# | C++ | Delphi | Flash | Java | JavaScript | Pascal | Perl | PHP | Python | Ruby | Visual Basic
© Copyright 2011 Programmersheaven.com - All rights reserved.
Reproduction in whole or in part, in any form or medium without express written permission is prohibited.
Violators of this policy may be subject to legal action. Please read our Terms Of Use and Privacy Statement for more information.
Operated by CommunityHeaven, a BootstrapLabs company.