Index: trunk/MagicSoft/Mars/mbase/BaseLinkDef.h
===================================================================
--- trunk/MagicSoft/Mars/mbase/BaseLinkDef.h	(revision 768)
+++ trunk/MagicSoft/Mars/mbase/BaseLinkDef.h	(revision 843)
@@ -29,4 +29,5 @@
 
 #pragma link C++ class MReadTree;
+#pragma link C++ class MWriteAsciiFile;
 
 #pragma link C++ class MArray;
Index: trunk/MagicSoft/Mars/mbase/MEvtLoop.cc
===================================================================
--- trunk/MagicSoft/Mars/mbase/MEvtLoop.cc	(revision 768)
+++ trunk/MagicSoft/Mars/mbase/MEvtLoop.cc	(revision 843)
@@ -54,4 +54,6 @@
 
 #include "MLog.h"
+#include "MLogManip.h"
+
 #include "MParList.h"
 #include "MTaskList.h"
@@ -87,5 +89,5 @@
     if (!fParList)
     {
-        *fLog << "MEvtLoop::Eventloop - Error: Parlist not initialized." << endl;
+        *fLog << dbginf << "Parlist not initialized." << endl;
         return kFALSE;
     }
@@ -98,5 +100,5 @@
     if (!fTaskList)
     {
-        *fLog << "MEvtLoop::Eventloop - Error: Cannot find tasklist '" << tlist << "' in parameter list." << endl;
+        *fLog << dbginf << "Cannot find tasklist '" << tlist << "' in parameter list." << endl;
         return kFALSE;
     }
Index: trunk/MagicSoft/Mars/mbase/MParContainer.cc
===================================================================
--- trunk/MagicSoft/Mars/mbase/MParContainer.cc	(revision 768)
+++ trunk/MagicSoft/Mars/mbase/MParContainer.cc	(revision 843)
@@ -53,4 +53,8 @@
     *fName = *(named.fName);
     *fTitle = *(named.fTitle);
+
+    fLog = named.fLog;
+
+    fHasChanged = named.fHasChanged;
 }
 
@@ -65,4 +69,6 @@
         *fName  = *(rhs.fName);
         *fTitle = *(rhs.fTitle);
+        fLog    = rhs.fLog;
+        fHasChanged = rhs.fHasChanged;
     }
     return *this;
@@ -89,4 +95,6 @@
     *(((MParContainer&)obj).fName)  = *fName;
     *(((MParContainer&)obj).fTitle) = *fTitle;
+    ((MParContainer&)obj).fLog   = fLog;
+    ((MParContainer&)obj).fHasChanged = fHasChanged;
 }
 
Index: trunk/MagicSoft/Mars/mbase/MParContainer.h
===================================================================
--- trunk/MagicSoft/Mars/mbase/MParContainer.h	(revision 768)
+++ trunk/MagicSoft/Mars/mbase/MParContainer.h	(revision 843)
@@ -35,12 +35,14 @@
 
 protected:
-    MLog    *fLog;    //! The general log facility for this object, initialized with the global object
+    MLog    *fLog;        //! The general log facility for this object, initialized with the global object
 
-    TString *fName;   //! parameter container identifier (name)
-    TString *fTitle;  //! parameter container title
+    TString *fName;       //! parameter container identifier (name)
+    TString *fTitle;      //! parameter container title
+
+    Bool_t   fHasChanged; //! should be set to true if the contents of the container is changed somehow
 
 public:
-    MParContainer(const char *name="", const char *title="") : fLog(&gLog) { Init(name, title); }
-    MParContainer(const TString &name, const TString &title) : fLog(&gLog) { Init(name, title); }
+    MParContainer(const char *name="", const char *title="") : fLog(&gLog), fHasChanged(kFALSE) { Init(name, title); }
+    MParContainer(const TString &name, const TString &title) : fLog(&gLog), fHasChanged(kFALSE) { Init(name, title); }
     MParContainer(const MParContainer &named);
     MParContainer& operator=(const MParContainer& rhs);
@@ -65,4 +67,9 @@
     virtual Int_t    Sizeof() const;
 
+    virtual void     Reset() {};
+
+    virtual Bool_t HasChanged() { return fHasChanged; }
+    virtual void   SetHasChanged(Bool_t flag=kTRUE) { fHasChanged=flag; }
+
     virtual void AsciiRead(ifstream &fin) {};
     virtual void AsciiWrite(ofstream &fout) const {};
Index: trunk/MagicSoft/Mars/mbase/MParList.cc
===================================================================
--- trunk/MagicSoft/Mars/mbase/MParList.cc	(revision 768)
+++ trunk/MagicSoft/Mars/mbase/MParList.cc	(revision 843)
@@ -251,7 +251,39 @@
 void MParList::Print(Option_t *t)
 {
-  *fLog << dbginf << "ParList: " << this->GetName() << " <" << this->GetTitle() << ">" << endl;
-  *fLog << endl;
-  
-}
-
+    *fLog << dbginf << "ParList: " << this->GetName() << " <" << this->GetTitle() << ">" << endl;
+    *fLog << endl;
+}
+
+// --------------------------------------------------------------------------
+//
+//   Sets the flags off all containers in the list (and the list
+//   itself) to unchanged
+//
+void MParList::SetHasChanged(Bool_t flag)
+{
+    TIter Next(&fContainer);
+
+    MParContainer *cont=NULL;
+
+    //
+    // loop over all tasks for preproccesing
+    //
+    while ( (cont=(MParContainer*)Next()) )
+        cont->SetHasChanged(flag);
+
+    MParContainer::SetHasChanged(flag);
+}
+
+void MParList::Reset()
+{
+    return;
+    TIter Next(&fContainer);
+
+    MParContainer *cont=NULL;
+
+    //
+    // loop over all tasks for preproccesing
+    //
+    while ( (cont=(MParContainer*)Next()) )
+        cont->Reset();
+}
Index: trunk/MagicSoft/Mars/mbase/MParList.h
===================================================================
--- trunk/MagicSoft/Mars/mbase/MParList.h	(revision 768)
+++ trunk/MagicSoft/Mars/mbase/MParList.h	(revision 843)
@@ -44,4 +44,7 @@
     MParContainer *FindCreateObj(const char *classname, const char *objname=NULL);
 
+    void Reset();
+    void SetHasChanged(Bool_t flag=kTRUE);
+
     void Print(Option_t *t = NULL);
 
Index: trunk/MagicSoft/Mars/mbase/MTaskList.cc
===================================================================
--- trunk/MagicSoft/Mars/mbase/MTaskList.cc	(revision 768)
+++ trunk/MagicSoft/Mars/mbase/MTaskList.cc	(revision 843)
@@ -135,4 +135,6 @@
     *fLog << "Preprocessing... " << flush;
 
+    fParList = pList;
+
     //
     //  create the Iterator over the tasklist
@@ -149,5 +151,5 @@
         *fLog << task->GetName() << "... " << flush;
 
-        if (!task->PreProcess( pList ))
+        if (!task->PreProcess(fParList))
             return kFALSE;
     }
@@ -164,4 +166,11 @@
 Bool_t MTaskList::Process()
 {
+    //
+    // Reset the HasChanged flag.
+    // Reset all containers.
+    //
+    fParList->SetHasChanged(kFALSE);
+    fParList->Reset();
+
     //
     //  create the Iterator for the TaskList
@@ -218,4 +227,7 @@
     *fLog << "Postprocessing... " << flush;
 
+    // FIXME: At the moment all containers are post processed independ of
+    // whether it was preprocessed or not.
+
     //
     //  create the Iterator for the TaskList
Index: trunk/MagicSoft/Mars/mbase/MTaskList.h
===================================================================
--- trunk/MagicSoft/Mars/mbase/MTaskList.h	(revision 768)
+++ trunk/MagicSoft/Mars/mbase/MTaskList.h	(revision 843)
@@ -25,4 +25,5 @@
 private:
     TOrdCollection fTasks;	// Container for the ordered list of different tasks
+    MParList      *fParList;
 
 public:
