Index: trunk/BNC/RTCM3/ephemeris.cpp
===================================================================
--- trunk/BNC/RTCM3/ephemeris.cpp	(revision 4012)
+++ trunk/BNC/RTCM3/ephemeris.cpp	(revision 4013)
@@ -1043,2 +1043,95 @@
   _ok = false;
 }
+
+// RINEX Format String
+//////////////////////////////////////////////////////////////////////////////
+QString t_ephGlo::toString(double /* version */) const {
+  return "";
+}
+
+// RINEX Format String
+//////////////////////////////////////////////////////////////////////////////
+QString t_ephGal::toString(double /* version */) const {
+  return "";
+}
+
+// RINEX Format String
+//////////////////////////////////////////////////////////////////////////////
+QString t_ephGPS::toString(double version) const {
+
+  QString rnxStr;
+  
+  bncTime tt(_GPSweek, _GPSweeks);
+  unsigned year, month, day, hour, min;
+  double sec;
+  tt.civil_date(year, month, day);
+  tt.civil_time(hour, min, sec);
+  
+  QTextStream out(&rnxStr);
+
+  if (version < 3.0) {
+    out << _prn << QString(" %1 %2 %3 %4 %5 %6")
+      .arg(year % 100, 2, 10, QChar('0'))
+      .arg(month,      2)
+      .arg(day,        2)
+      .arg(hour,       2)
+      .arg(min,        2)
+      .arg(int(sec),   2);
+  }
+  else {
+    out << _prn << QString(" %1 %2 %3 %4 %5 %6")
+      .arg(year,     4)
+      .arg(month,    2, 10, QChar('0'))
+      .arg(day,      2, 10, QChar('0'))
+      .arg(hour,     2, 10, QChar('0'))
+      .arg(min,      2, 10, QChar('0'))
+      .arg(int(sec), 2, 10, QChar('0'));
+  }
+  
+  out << QString("%1%2%3\n")
+    .arg(_clock_bias,      19, 'e', 12)
+    .arg(_clock_drift,     19, 'e', 12)
+    .arg(_clock_driftrate, 19, 'e', 12);
+
+  out << QString("    %1%2%3%4\n")
+    .arg(_IODE,    19, 'e', 12)
+    .arg(_Crs,     19, 'e', 12)
+    .arg(_Delta_n, 19, 'e', 12)
+    .arg(_M0,      19, 'e', 12);
+
+  out << QString("    %1%2%3%4\n")
+    .arg(_Cuc,    19, 'e', 12)
+    .arg(_e,      19, 'e', 12)
+    .arg(_Cus,    19, 'e', 12)
+    .arg(_sqrt_A, 19, 'e', 12);
+
+  out << QString("    %1%2%3%4\n")
+    .arg(_TOE,    19, 'e', 12)
+    .arg(_Cic,    19, 'e', 12)
+    .arg(_OMEGA0, 19, 'e', 12)
+    .arg(_Cis,    19, 'e', 12);
+
+  out << QString("    %1%2%3%4\n")
+    .arg(_i0,       19, 'e', 12)
+    .arg(_Crc,      19, 'e', 12)
+    .arg(_omega,    19, 'e', 12)
+    .arg(_OMEGADOT, 19, 'e', 12);
+
+  out << QString("    %1%2%3%4\n")
+    .arg(_IDOT, 19, 'e', 12)
+    .arg(0.0,   19, 'e', 12)
+    .arg(0.0,   19, 'e', 12)
+    .arg(0.0,   19, 'e', 12);
+
+  out << QString("    %1%2%3%4\n")
+    .arg(0.0,     19, 'e', 12)
+    .arg(_health, 19, 'e', 12)
+    .arg(_TGD,    19, 'e', 12)
+    .arg(_IODC,   19, 'e', 12);
+
+  out << QString("    %1%2\n")
+    .arg(0.0,19, 'e', 12)
+    .arg(0.0,19, 'e', 12);
+
+  return rnxStr;
+}
Index: trunk/BNC/RTCM3/ephemeris.h
===================================================================
--- trunk/BNC/RTCM3/ephemeris.h	(revision 4012)
+++ trunk/BNC/RTCM3/ephemeris.h	(revision 4013)
@@ -32,4 +32,6 @@
   virtual e_type type() const = 0;
 
+  virtual QString toString(double version) const = 0;
+
   bool     ok() const {return _ok;}
   bool     isNewerThan(const t_eph* eph) const;
@@ -79,4 +81,6 @@
 
   virtual e_type type() const {return t_eph::GPS;}
+
+  virtual QString toString(double version) const;
 
   double TOC() const {return _TOC;}
@@ -134,4 +138,6 @@
 
   virtual e_type type() const {return t_eph::GLONASS;}
+
+  virtual QString toString(double version) const;
 
   virtual void position(int GPSweek, double GPSweeks, 
@@ -177,4 +183,6 @@
   t_ephGal(float rnxVersion, const QStringList& lines);
   virtual ~t_ephGal() {}
+
+  virtual QString toString(double version) const;
 
   virtual e_type type() const {return t_eph::Galileo;}
Index: trunk/BNC/rinex/reqcedit.cpp
===================================================================
--- trunk/BNC/rinex/reqcedit.cpp	(revision 4012)
+++ trunk/BNC/rinex/reqcedit.cpp	(revision 4013)
@@ -100,4 +100,10 @@
 ////////////////////////////////////////////////////////////////////////////
 void t_reqcEdit::editObservations() {
+
+  // Easy Exit
+  // ---------
+  if (_obsFileNames.isEmpty() || _outObsFileName.isEmpty()) {
+    return;
+  }
 
   // Initialize input observation files, sort them according to start time
@@ -230,4 +236,10 @@
 void t_reqcEdit::editEphemerides() {
 
+  // Easy Exit
+  // ---------
+  if (_navFileNames.isEmpty() || _outNavFileName.isEmpty()) {
+    return;
+  }
+
   // Read All Ephemerides
   // --------------------
Index: trunk/BNC/rinex/rnxnavfile.cpp
===================================================================
--- trunk/BNC/rinex/rnxnavfile.cpp	(revision 4012)
+++ trunk/BNC/rinex/rnxnavfile.cpp	(revision 4013)
@@ -271,37 +271,4 @@
 ////////////////////////////////////////////////////////////////////////////
 void t_rnxNavFile::writeEph(const t_eph* eph) {
-  if (version() < 3.0) {
-    writeEphV2(eph);
-  }
-  else {
-    writeEphV3(eph);
-  }
-}
-
-// 
-////////////////////////////////////////////////////////////////////////////
-void t_rnxNavFile::writeEphV2(const t_eph* eph) {
-}
-
-// 
-////////////////////////////////////////////////////////////////////////////
-void t_rnxNavFile::writeEphV3(const t_eph* eph) {
-
-  bncTime tt(eph->GPSweek(), eph->GPSweeks());
-
-  unsigned year, month, day, hour, min;
-  double sec;
-  tt.civil_date(year, month, day);
-  tt.civil_time(hour, min, sec);
-
-  QString dateStr;
-  QTextStream(&dateStr) << QString(" %1 %2 %3 %4 %5 %6")
-    .arg(year,     4)
-    .arg(month,    2, 10, QChar('0'))
-    .arg(day,      2, 10, QChar('0'))
-    .arg(hour,     2, 10, QChar('0'))
-    .arg(min,      2, 10, QChar('0'))
-    .arg(int(sec), 2, 10, QChar('0'));
-
-  *_stream << eph->prn() << dateStr << endl;
-}
+  *_stream << eph->toString(version());
+}
Index: trunk/BNC/rinex/rnxnavfile.h
===================================================================
--- trunk/BNC/rinex/rnxnavfile.h	(revision 4012)
+++ trunk/BNC/rinex/rnxnavfile.h	(revision 4013)
@@ -69,6 +69,4 @@
  private:
   void read(QTextStream* stream);
-  void writeEphV2(const t_eph* eph);
-  void writeEphV3(const t_eph* eph);
 
   e_inpOut            _inpOut;
