Index: src/Actions/FragmentationAction/FragmentationAction.cpp
===================================================================
--- src/Actions/FragmentationAction/FragmentationAction.cpp	(revision 48ab70ab46459550f30b5526d868ebaef5b918e5)
+++ src/Actions/FragmentationAction/FragmentationAction.cpp	(revision e4b5de3092d7deccd5df82703dcd50757372d70a)
@@ -25,5 +25,5 @@
 #include "Actions/MapOfActions.hpp"
 
-const char FragmentationFragmentationAction::NAME[] = "subspace-dissect";
+const char FragmentationFragmentationAction::NAME[] = "fragment-mol";
 
 FragmentationFragmentationAction::FragmentationFragmentationAction() :
@@ -36,8 +36,30 @@
 Action::state_ptr FragmentationFragmentationAction::performCall() {
   Dialog *dialog = UIFactory::getInstance().makeDialog();
+  clock_t start,end;
+  molecule *mol = NULL;
+  double distance = -1.;
+  int order = 0;
+  config *configuration = World::getInstance().getConfig();
+  int ExitFlag = 0;
 
-  dialog->queryEmpty(NAME, MapOfActions::getInstance().getDescription(NAME));
+  cout << "pre-dialog"<< endl;
+  dialog->queryMolecule(NAME, &mol, MapOfActions::getInstance().getDescription(NAME));
+  dialog->queryDouble("distance", &distance, MapOfActions::getInstance().getDescription("distance"));
+  dialog->queryInt("order", &order, MapOfActions::getInstance().getDescription("order"));
 
   if(dialog->display()) {
+    cout << "POST-dialog"<< endl;
+    ASSERT(mol != NULL, "No molecule has been picked for fragmentation.");
+    DoLog(0) && (Log() << Verbose(0) << "Fragmenting molecule with bond distance " << distance << " angstroem, order of " << order << "." << endl);
+    DoLog(0) && (Log() << Verbose(0) << "Creating connection matrix..." << endl);
+    start = clock();
+    mol->CreateAdjacencyList(distance, configuration->GetIsAngstroem(), &BondGraph::CovalentMinMaxDistance, NULL);
+    DoLog(0) && (Log() << Verbose(0) << "Fragmenting molecule with current connection matrix ..." << endl);
+    if (mol->hasBondStructure()) {
+      ExitFlag = mol->FragmentMolecule(order, configuration);
+    }
+    World::getInstance().setExitFlag(ExitFlag);
+    end = clock();
+    DoLog(0) && (Log() << Verbose(0) << "Clocks for this operation: " << (end-start) << ", time: " << ((double)(end-start)/CLOCKS_PER_SEC) << "s." << endl);
     delete dialog;
     return Action::success;
Index: src/Actions/MapOfActions.cpp
===================================================================
--- src/Actions/MapOfActions.cpp	(revision 48ab70ab46459550f30b5526d868ebaef5b918e5)
+++ src/Actions/MapOfActions.cpp	(revision e4b5de3092d7deccd5df82703dcd50757372d70a)
@@ -120,4 +120,5 @@
   DescriptionMap["MaxDistance"] = "maximum distance in space";
   DescriptionMap["molecule-by-id"] = "index of a molecule";
+  DescriptionMap["order"] = "order of a discretization, dissection, ...";
   DescriptionMap["output-file"] = "name of the output file";
   DescriptionMap["periodic"] = "system is constraint to periodic boundary conditions (y/n)";
@@ -216,4 +217,5 @@
   TypeMap["MaxDistance"] = Double;
   TypeMap["molecule-by-id"] = Molecule;
+  TypeMap["order"] = Integer;
   TypeMap["output-file"] = String;
   TypeMap["periodic"] = Boolean;
@@ -241,5 +243,5 @@
 //	generic.insert("fastparsing");
   generic.insert("fill-molecule");
-//  generic.insert("fragment-mol");
+  generic.insert("fragment-mol");
   generic.insert("help");
 //	generic.insert("linear-interpolate");
@@ -285,10 +287,11 @@
 
     // hidden arguments
-//  generic.insert("distance");
-    generic.insert("DoRotate");
-    generic.insert("distances");
-    generic.insert("lengths");
-    generic.insert("MaxDistance");
-    generic.insert("molecule-by-id");
+  generic.insert("distance");
+  generic.insert("DoRotate");
+  generic.insert("distances");
+  generic.insert("lengths");
+  generic.insert("MaxDistance");
+  generic.insert("molecule-by-id");
+  generic.insert("order");
 }
 
Index: src/UIElements/CommandLineUI/CommandLineWindow.cpp
===================================================================
--- src/UIElements/CommandLineUI/CommandLineWindow.cpp	(revision 48ab70ab46459550f30b5526d868ebaef5b918e5)
+++ src/UIElements/CommandLineUI/CommandLineWindow.cpp	(revision e4b5de3092d7deccd5df82703dcd50757372d70a)
@@ -26,4 +26,5 @@
 #include "Actions/FragmentationAction/DepthFirstSearchAction.hpp"
 #include "Actions/FragmentationAction/SubgraphDissectionAction.hpp"
+#include "Actions/FragmentationAction/FragmentationAction.hpp"
 #include "Actions/MoleculeAction/BondFileAction.hpp"
 #include "Actions/MoleculeAction/ChangeNameAction.hpp"
@@ -119,4 +120,6 @@
 {
   new FragmentationDepthFirstSearchAction();
+  new FragmentationFragmentationAction();
+  new FragmentationSubgraphDissectionAction();
 }
 
Index: src/World.cpp
===================================================================
--- src/World.cpp	(revision 48ab70ab46459550f30b5526d868ebaef5b918e5)
+++ src/World.cpp	(revision e4b5de3092d7deccd5df82703dcd50757372d70a)
@@ -96,4 +96,12 @@
 };
 
+int World::getExitFlag() {
+  return ExitFlag;
+}
+
+void World::setExitFlag(int flag) {
+  if (ExitFlag < flag)
+    ExitFlag = flag;
+}
 
 /******************** Methods to change World state *********************/
@@ -279,4 +287,5 @@
     periode(new periodentafel),
     configuration(new config),
+    ExitFlag(0),
     atoms(),
     currAtomId(0),
Index: src/World.hpp
===================================================================
--- src/World.hpp	(revision 48ab70ab46459550f30b5526d868ebaef5b918e5)
+++ src/World.hpp	(revision e4b5de3092d7deccd5df82703dcd50757372d70a)
@@ -142,4 +142,14 @@
   void setDefaultName(char * name);
 
+  /*
+   * get the ExitFlag
+   */
+  int getExitFlag();
+
+  /*
+   * set the ExitFlag
+   */
+  void setExitFlag(int flag);
+
   /***** Methods to work with the World *****/
 
@@ -244,4 +254,5 @@
   static double *cell_size;
   static char *defaultName;
+  int ExitFlag;
 public:
   AtomSet atoms;
Index: src/builder.cpp
===================================================================
--- src/builder.cpp	(revision 48ab70ab46459550f30b5526d868ebaef5b918e5)
+++ src/builder.cpp	(revision e4b5de3092d7deccd5df82703dcd50757372d70a)
@@ -2237,20 +2237,16 @@
             case 'f':
               if (ExitFlag == 0) ExitFlag = 1;
-              if ((argptr+1 >= argc) || (argv[argptr][0] == '-') || (!IsValidNumber(argv[argptr])) || (!IsValidNumber(argv[argptr+1]))) {
+              if ((argptr+1 >= argc) || (argv[argptr][0] == '-')) {
                 ExitFlag = 255;
                 DoeLog(0) && (eLog()<< Verbose(0) << "Not enough or invalid arguments for fragmentation: -f <max. bond distance> <bond order>" << endl);
                 performCriticalExit();
               } else {
-                DoLog(0) && (Log() << Verbose(0) << "Fragmenting molecule with bond distance " << argv[argptr] << " angstroem, order of " << argv[argptr+1] << "." << endl);
-                DoLog(0) && (Log() << Verbose(0) << "Creating connection matrix..." << endl);
-                start = clock();
-                mol->CreateAdjacencyList(atof(argv[argptr]), configuration.GetIsAngstroem(), &BondGraph::CovalentMinMaxDistance, NULL);
-                DoLog(0) && (Log() << Verbose(0) << "Fragmenting molecule with current connection matrix ..." << endl);
-                if (mol->hasBondStructure()) {
-                  ExitFlag = mol->FragmentMolecule(atoi(argv[argptr+1]), &configuration);
-                }
-                end = clock();
-                DoLog(0) && (Log() << Verbose(0) << "Clocks for this operation: " << (end-start) << ", time: " << ((double)(end-start)/CLOCKS_PER_SEC) << "s." << endl);
-                argptr+=2;
+                ArgcList.insert(argptr-1);
+                ArgcList.insert(argptr);
+                ArgcList.insert(argptr+1);
+                ArgcList.insert(argptr+2);
+                ArgcList.insert(argptr+3);
+                ArgcList.insert(argptr+4);
+                argptr+=5;
               }
               break;
@@ -2409,4 +2405,5 @@
       // handle arguments by ParseCommandLineOptions()
       ExitFlag = ParseCommandLineOptions(argc,argv,World::getInstance().getMolecules(),World::getInstance().getPeriode(),*World::getInstance().getConfig(), &ConfigFileName, ArgcList);
+      World::getInstance().setExitFlag(ExitFlag);
       // copy all remaining arguments to a new argv
       Arguments = new char *[ArgcList.size()];
@@ -2449,4 +2446,5 @@
   delete[](ConfigFileName);
 
+  ExitFlag = World::getInstance().getExitFlag();
   return (ExitFlag == 1 ? 0 : ExitFlag);
 }
