On Feb 1, 11:43 pm, psars...@ptc.com (Paryushan Sarsamkar) wrote: > I wanted to print some text on windows cmd in different colors, below is the > code that I am using which works fine on unix but not on windows L > > #!/usr/bin/perl > > use strict; > > use warnings; > > use Term::ANSIColor; > > print color("red"), "Stop!\n", color("reset"); > > print color("green"), "Go!\n", color("reset"); > > output - > > ←[31mStop! > > ←[0m←[32mGo! > > ←[0m > > Thanks, > > Paryushan
You need to add: use Win32::Console::ANSI; -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/