Index: /trunk/tools/czartool/Pantasks.pm
===================================================================
--- /trunk/tools/czartool/Pantasks.pm	(revision 30395)
+++ /trunk/tools/czartool/Pantasks.pm	(revision 30396)
@@ -123,8 +123,9 @@
         # sometimes a label can be on the same line as the panstasks prompt
         if ($line =~ m/pantasks: (.*)/) {
-            if (length($1) > 0) {push(@labels, $1);}
-            $passedHeader=1; next;
-        }
-        if ($passedHeader) {push(@labels, $line);}
+            $line = $1;
+            $passedHeader=1;
+        }
+
+        if ($passedHeader && length($line) > 0){push(@labels, $line);}
     }
 
@@ -196,3 +197,47 @@
     }
 }
+
+###########################################################################
+#
+# Gets current dates for this server
+#
+###########################################################################
+sub getDates {
+    my ($self, $server) = @_;
+
+    my @dates;
+
+    my $prefix;
+
+    if ($server eq "stdscience") {$prefix = "ns";}
+    elsif ($server eq "registration") {$prefix = "register";}
+
+    my @cmdOut = `echo "$prefix.show.dates;quit" | pantasks_client -c ~ipp/$server/ptolemy.rc 2>&1`;
+    my $line;
+    my $passedHeader=0;
+    foreach $line (@cmdOut) {
+
+        chomp($line);
+        if (!$self->outputOk($line)) {return \@dates;}
+
+        # sometimes content is on same line as pantasks prompt
+        if ($line =~ m/pantasks: (.*)/) {
+            $line =~ s/pantasks: //; 
+                $passedHeader=1;
+        }
+
+        if ($passedHeader && length($line) > 0){
+
+            # strip out only the date part
+            if ($line =~ m/([0-9]{4}-[0-9]{2}-[0-9]{2}).*/) {
+
+                push(@dates, $1);
+            }
+        }
+    }
+
+    return \@dates;
+}
+
+
 1;
