Index: trunk/psLib/psParseErrorCodes
===================================================================
--- trunk/psLib/psParseErrorCodes	(revision 4541)
+++ trunk/psLib/psParseErrorCodes	(revision 5223)
@@ -8,8 +8,10 @@
 
 my $data = "psErrorCodes.dat";
+my $outdir = ".";
 
 # Assign variables based on the presence of command line options to the script
 GetOptions(
     "data=s"  => \$data,
+    "outdir=s" => \$outdir,
     "verbose" => \$verbose,
     "help"    => \$help
@@ -51,6 +53,7 @@
 
 foreach (@ARGV) {
-    my $output = $_;
-    my $filename = $output.".in";
+    my $filename = $_.".in";
+    m/\/?([\w\.]+)$/;
+    my $output = "$outdir/$1";
 
     die "Failed to open input file '$filename'"
@@ -59,5 +62,5 @@
       if !open( OUTFILE, ">", $output );
 
-    print "\nOutput File:\n" if $verbose;
+    print "\nOutput File: $output\n" if $verbose;
     while (<INFILE>) {
         if (/\${ErrorCode}/ || /\${ErrorDescription}/ || /\${n}/) {
