Index: TXM/trunk/bundles/org.txm.annotation.kr.core/src/org/txm/annotation/kr/core/AnnotationManager.java
===================================================================
--- TXM/trunk/bundles/org.txm.annotation.kr.core/src/org/txm/annotation/kr/core/AnnotationManager.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.annotation.kr.core/src/org/txm/annotation/kr/core/AnnotationManager.java	(revision 3731)
@@ -81,6 +81,7 @@
 		AnnotationWriter writer = new AnnotationWriter(corpus);
 		if (writer.writeAnnotations(annots, monitor)) {
 			Log.info(KRAnnotationCoreMessages.annotationSuccesfullyWritten);
+			corpus.getProject().appendToHistory(NLS.bind(KRAnnotationCoreMessages.savingP0Annotations, annots.size()));
 			tempManager.deleteAnnotations();
 			dirty = false;
 			return true;
Index: TXM/trunk/bundles/org.txm.core/src/java/org/txm/Toolbox.java
===================================================================
--- TXM/trunk/bundles/org.txm.core/src/java/org/txm/Toolbox.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.core/src/java/org/txm/Toolbox.java	(revision 3731)
@@ -525,8 +525,8 @@
 	 */
 	public static void shutdown() {
 		
-		stopEnginesManagers();
 		
+		
 		try {
 			// FIXME: tmp solution before IProject: remove all not persistable result nodes
 			// TXMPreferences.deleteAllNotPersistableResultsNodes();
@@ -540,10 +540,18 @@
 			
 			// save projects parameters
 			if (Toolbox.workspace != null) {
+				
+				Toolbox.workspace.onWorkspaceClose();
+				
 				TXMResult.deleteAllNonPersistentResults(Toolbox.workspace);
+				
 				Toolbox.workspace.saveParameters(true);
 			}
-			Toolbox.workspace = null;
+			
+			stopEnginesManagers();
+			
+			
+			
 			state = false;
 			
 			// save global preferences
Index: TXM/trunk/bundles/org.txm.core/src/java/org/txm/core/engines/ScriptedImportEngine.java
===================================================================
--- TXM/trunk/bundles/org.txm.core/src/java/org/txm/core/engines/ScriptedImportEngine.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.core/src/java/org/txm/core/engines/ScriptedImportEngine.java	(revision 3731)
@@ -1,7 +1,6 @@
 package org.txm.core.engines;
 
 import java.io.File;
-import java.util.List;
 
 import org.eclipse.core.runtime.IProgressMonitor;
 import org.eclipse.core.runtime.IStatus;
Index: TXM/trunk/bundles/org.txm.core/src/java/org/txm/core/results/TXMResult.java
===================================================================
--- TXM/trunk/bundles/org.txm.core/src/java/org/txm/core/results/TXMResult.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.core/src/java/org/txm/core/results/TXMResult.java	(revision 3731)
@@ -371,6 +371,13 @@
 	public void onProjectOpen() {
 
 	}
+	
+	/**
+	 * Do something when the workspace is closed = TXM is closing
+	 */
+	public void onWorkspaceClose() {
+		
+	}
 
 	/**
 	 * Locks/unlocks the result.
Index: TXM/trunk/bundles/org.txm.core/src/java/org/txm/objects/Workspace.java
===================================================================
--- TXM/trunk/bundles/org.txm.core/src/java/org/txm/objects/Workspace.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.core/src/java/org/txm/objects/Workspace.java	(revision 3731)
@@ -41,6 +41,7 @@
 import org.eclipse.osgi.util.NLS;
 import org.txm.Toolbox;
 import org.txm.core.messages.TXMCoreMessages;
+import org.txm.core.preferences.TXMPreferences;
 import org.txm.core.results.TXMParameters;
 import org.txm.core.results.TXMResult;
 import org.txm.utils.LogMonitor;
@@ -207,6 +208,17 @@
 		return corporaProject.getLocation().toFile().getAbsoluteFile();
 	}
 
+	public void onWorkspaceClose() {
+		
+		List<TXMResult> todo = this.getChildren();
+		while (todo.size() > 0) {
+			TXMResult r = null;
+			r = todo.remove(0);
+			todo.addAll(0, r.getChildren());
+			r.onWorkspaceClose();
+		}
+	}
+	
 	/**
 	 * 
 	 * @param binCorpusDir the directory to scan
Index: TXM/trunk/bundles/org.txm.core/src/java/org/txm/objects/Project.java
===================================================================
--- TXM/trunk/bundles/org.txm.core/src/java/org/txm/objects/Project.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.core/src/java/org/txm/objects/Project.java	(revision 3731)
@@ -29,11 +29,15 @@
 
 
 import java.io.File;
+import java.io.FileNotFoundException;
 import java.io.IOException;
+import java.io.PrintWriter;
+import java.io.UnsupportedEncodingException;
 import java.lang.reflect.Constructor;
 import java.net.MalformedURLException;
 import java.util.ArrayList;
 import java.util.Arrays;
+import java.util.Date;
 import java.util.HashMap;
 import java.util.HashSet;
 import java.util.List;
@@ -249,12 +253,17 @@
 				
 				rcpProject.open(monitor);
 				
+				
 				initRCPStuffs(monitor);
 				
 				monitor.subTask("Loading results");
 				
 				this.loadResults(null);
 				
+				for (TXMResult r : getDeepChildren()) {
+					r.onProjectOpen();
+				}
+				
 				for (TXMResult cb : getCorpora()) {
 					try {
 						if (!cb.compute(false)) {
@@ -280,7 +289,7 @@
 	public boolean close(IProgressMonitor monitor) {
 		if (rcpProject != null && rcpProject.isOpen()) {
 			try {
-				for (TXMResult r : getChildren()) {
+				for (TXMResult r : getDeepChildren()) {
 					r.onProjectClose();
 				}
 				this.saveParameters(true);
@@ -1573,6 +1582,46 @@
 	}
 	
 	/**
+	 * Append the line prefixed with the date
+	 * 
+	 * @param line
+	 */
+	public void appendToHistory(String line) {
+		
+		File logFile = new File(this.getProjectDirectory(), "HISTORY");
+		PrintWriter writer = null;
+		try {
+			writer = IOUtils.getWriter(logFile, true);
+			writer.println(TXMResult.PRETTY_TIME_FORMAT.format(new Date()) + " - " + line);
+			writer.close();
+		} catch (UnsupportedEncodingException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		} catch (FileNotFoundException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		} finally {
+			if ((writer != null)) writer.close();
+		}
+	}
+	
+	public void writeHistory(String history) {
+		
+		File logFile = new File(this.getProjectDirectory(), "HISTORY");
+		IOUtils.write(logFile, history);
+	}
+	
+	public String getHistory() throws IOException {
+		
+		File logFile = new File(this.getProjectDirectory(), "HISTORY");
+		if (logFile.exists()) {
+			return IOUtils.getText(logFile);
+		} else {
+			return "no history yet";
+		}
+	}
+	
+	/**
 	 * Stores parameters of all the Project and all its results in nodes and saves them in the properties files.
 	 * 
 	 * @return true if the save has well been done otherwise false
Index: TXM/trunk/bundles/org.txm.rcp/src/main/java/org/txm/rcp/commands/function/WordPropertiesFromTable.java
===================================================================
--- TXM/trunk/bundles/org.txm.rcp/src/main/java/org/txm/rcp/commands/function/WordPropertiesFromTable.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.rcp/src/main/java/org/txm/rcp/commands/function/WordPropertiesFromTable.java	(revision 3731)
@@ -30,7 +30,7 @@
 		
 		MainCorpus corpus = (MainCorpus)first;
 		
-		File script = new File(Toolbox.getTxmHomePath(),         "/scripts/groovy/user/org/txm/macro/annotation/ImportWordPropertiesFromTableMacro.groovy"); //$NON-NLS-1$
+		File script = new File(Toolbox.getTxmHomePath(), "/scripts/groovy/user/org/txm/macro/annotation/ImportWordPropertiesFromTableMacro.groovy"); //$NON-NLS-1$
 		//File parametersFile = new File(Toolbox.getTxmHomePath(), "/scripts/groovy/user/org/txm/macro/annotation/ImportWordPropertiesFromTableMacro.properties");
 
 		HashMap<String, Object> defaultParameters = new HashMap<String, Object>();
@@ -38,6 +38,8 @@
 		defaultParameters.put("csvFile", corpus.getName()+"_annotations.tsv"); //$NON-NLS-1$ //$NON-NLS-2$
 		
 		ExecuteGroovyMacro.execute(script.getAbsolutePath(), part, selection, null, null, defaultParameters); //$NON-NLS-1$
+		
+		
 		return null;
 	}
 	
Index: TXM/trunk/bundles/org.txm.rcp/src/main/java/org/txm/rcp/commands/workspace/UpdateCorpus.java
===================================================================
--- TXM/trunk/bundles/org.txm.rcp/src/main/java/org/txm/rcp/commands/workspace/UpdateCorpus.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.rcp/src/main/java/org/txm/rcp/commands/workspace/UpdateCorpus.java	(revision 3731)
@@ -2,6 +2,7 @@
 
 import java.io.File;
 import java.io.FileFilter;
+import java.util.Date;
 
 import org.eclipse.core.commands.AbstractHandler;
 import org.eclipse.core.commands.ExecutionEvent;
@@ -15,6 +16,7 @@
 import org.eclipse.osgi.util.NLS;
 import org.eclipse.swt.widgets.Display;
 import org.eclipse.ui.handlers.HandlerUtil;
+import org.txm.Toolbox;
 import org.txm.core.preferences.TBXPreferences;
 import org.txm.objects.Project;
 import org.txm.rcp.commands.CloseEditorsUsing;
@@ -144,6 +146,8 @@
 				try {
 					if (project.compute(monitor, true)) { // TODO children should be recomputed later only when the user needs it
 						
+						project.appendToHistory("Updated");
+						
 						this.syncExec(new Runnable() {
 							
 							@Override
Index: TXM/trunk/bundles/org.txm.rcp/src/main/java/org/txm/rcp/ApplicationWorkbenchAdvisor.java
===================================================================
--- TXM/trunk/bundles/org.txm.rcp/src/main/java/org/txm/rcp/ApplicationWorkbenchAdvisor.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.rcp/src/main/java/org/txm/rcp/ApplicationWorkbenchAdvisor.java	(revision 3731)
@@ -513,6 +513,7 @@
 	 */
 	@Override
 	public void postShutdown() {
+		
 		callPreStopScript();
 
 		Toolbox.shutdown();
Index: TXM/trunk/bundles/org.txm.rcp/src/main/java/org/txm/rcp/swt/widget/parameters/SeparatorField.java
===================================================================
--- TXM/trunk/bundles/org.txm.rcp/src/main/java/org/txm/rcp/swt/widget/parameters/SeparatorField.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.rcp/src/main/java/org/txm/rcp/swt/widget/parameters/SeparatorField.java	(revision 3731)
@@ -1,13 +1,10 @@
 package org.txm.rcp.swt.widget.parameters;
 
 import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.FontData;
 import org.eclipse.swt.layout.GridData;
 import org.eclipse.swt.layout.GridLayout;
 import org.eclipse.swt.widgets.Composite;
 import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Text;
 import org.kohsuke.args4j.NamedOptionDef;
 
 /**
@@ -37,8 +34,8 @@
 			l.setLayoutData(gd);
 			l.setText(str);
 			l.setToolTipText(getWidgetUsage());
-			Font f = parent.getFont();
-			l.setFont(new Font(f.getDevice(), new FontData(f.getFontData()[0].getName(), f.getFontData()[0].getHeight(), f.getFontData()[0].getStyle()|SWT.BOLD)));
+//			Font f = parent.getFont();
+//			l.setFont(new Font(Display.getCurrent(), new FontData(f.getFontData()[0].getName(), f.getFontData()[0].getHeight(), f.getFontData()[0].getStyle()|SWT.BOLD)));
 			Label dt = new Label(this, SWT.SEPARATOR | SWT.HORIZONTAL);
 			dt.setLayoutData(new GridData(SWT.FILL, SWT.END, true, false));
 			dt.setToolTipText(getWidgetUsage());
Index: TXM/trunk/bundles/org.txm.rcp/src/main/java/org/txm/rcp/swt/widget/QueryWidget.java
===================================================================
--- TXM/trunk/bundles/org.txm.rcp/src/main/java/org/txm/rcp/swt/widget/QueryWidget.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.rcp/src/main/java/org/txm/rcp/swt/widget/QueryWidget.java	(revision 3731)
@@ -78,21 +78,21 @@
 
 		h = null;
 		
-//		if (this.project != null) {
-//			h = this.project.getFirstChild(QueryHistory.class);
-//
-//			if (h == null) {
-//				h = new QueryHistory(project);
-//			}
-//		}
-//		
-//		try { // load history from queries.txt file
-//			h.compute(false);
-//		} catch (InterruptedException e) {
-//			// TODO Auto-generated catch block
-//			e.printStackTrace();
-//		}
+		if (this.project != null) {
+			h = this.project.getFirstChild(QueryHistory.class);
+
+			if (h == null) {
+				h = new QueryHistory(project);
+			}
+		}
 		
+		try { // load history from queries.txt file
+			h.compute(false);
+		} catch (InterruptedException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+		
 		setHistoryItems();
 	}
 	
Index: TXM/trunk/bundles/org.txm.tigersearch.rcp/src/org/txm/tigersearch/commands/ImportTIGERAnnotations.java
===================================================================
--- TXM/trunk/bundles/org.txm.tigersearch.rcp/src/org/txm/tigersearch/commands/ImportTIGERAnnotations.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.tigersearch.rcp/src/org/txm/tigersearch/commands/ImportTIGERAnnotations.java	(revision 3731)
@@ -232,6 +232,9 @@
 		Log.info("Finalizing TIGERSearch corpus");
 		if (numberOfWordsAnnotated > 0) { // copy the TIGERcorpus to import
 			FileCopy.copyFiles(tigerCorpusDirectory, tigerCorpusExistingDirectory);
+			
+			corpus.getProject().appendToHistory("TIGER Annotations imported from "+tigerDirectory);
+			
 			Log.info("Done. " + numberOfWordsAnnotated + " words annotated.");
 		}
 		else {
Index: TXM/trunk/bundles/org.txm.analec.rcp/src/org/txm/annotation/urs/commands/ImportTEIAnnotations.java
===================================================================
--- TXM/trunk/bundles/org.txm.analec.rcp/src/org/txm/annotation/urs/commands/ImportTEIAnnotations.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.analec.rcp/src/org/txm/annotation/urs/commands/ImportTEIAnnotations.java	(revision 3731)
@@ -76,6 +76,7 @@
 							Log.warning(Messages.ImportTEIAnnotations_2);
 							return Status.CANCEL_STATUS;
 						} else {
+							mainCorpus.getProject().appendToHistory("URS annotations imported from "+ directory +" : "+analecCorpus.getStructure().toString());
 							return Status.OK_STATUS;
 						}
 					} catch (Throwable e) {
@@ -136,6 +137,9 @@
 		if (ret) {
 			Log.info(TXMCoreMessages.bind(Messages.ImportTEIAnnotations_5, analecCorpus.getToutesUnites().size(), analecCorpus.getToutesRelations().size(), analecCorpus.getTousSchemas().size()));
 			mainCorpus.setIsModified(true);
+			
+			mainCorpus.getProject().appendToHistory("URS Annotations imported from TEI files of "+annotationDirectory);
+			
 			CorporaView.refreshObject(mainCorpus);
 		}
 		return ret;
Index: TXM/trunk/bundles/org.txm.analec.rcp/src/org/txm/annotation/urs/commands/SaveCorpus.java
===================================================================
--- TXM/trunk/bundles/org.txm.analec.rcp/src/org/txm/annotation/urs/commands/SaveCorpus.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.analec.rcp/src/org/txm/annotation/urs/commands/SaveCorpus.java	(revision 3731)
@@ -87,6 +87,8 @@
 			Log.warning(Messages.SaveCorpus_5);
 			return false;
 		}
+		
+		mainCorpus.getProject().appendToHistory("URS annotations saved");
 
 		mainCorpus.setIsModified(false);
 		if (event != null) {
Index: TXM/trunk/bundles/org.txm.analec.rcp/src/org/txm/annotation/urs/commands/ImportGlozzAnnotations.java
===================================================================
--- TXM/trunk/bundles/org.txm.analec.rcp/src/org/txm/annotation/urs/commands/ImportGlozzAnnotations.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.analec.rcp/src/org/txm/annotation/urs/commands/ImportGlozzAnnotations.java	(revision 3731)
@@ -95,6 +95,8 @@
 		Log.info(Messages.ImportGlozzAnnotations_9);
 		URSCorpora.saveCorpus(analecCorpus);
 		
+		mainCorpus.getProject().appendToHistory("URS Annotations imported from "+aafile+", "+aamfile+" and "+acfile);
+		
 		Log.info(Messages.ImportGlozzAnnotations_10);
 		return true;
 	}
Index: TXM/trunk/bundles/org.txm.conllu.rcp/src/org/txm/conllu/rcp/commands/ExportCorpusAsFullCoNLLU.java
===================================================================
--- TXM/trunk/bundles/org.txm.conllu.rcp/src/org/txm/conllu/rcp/commands/ExportCorpusAsFullCoNLLU.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.conllu.rcp/src/org/txm/conllu/rcp/commands/ExportCorpusAsFullCoNLLU.java	(revision 3731)
@@ -42,6 +42,7 @@
 import org.eclipse.osgi.util.NLS;
 import org.eclipse.ui.handlers.HandlerUtil;
 import org.kohsuke.args4j.Option;
+import org.txm.conllu.core.function.ImportCoNLLUAnnotations;
 import org.txm.rcp.swt.widget.parameters.ParametersDialog;
 import org.txm.searchengine.cqp.CQPSearchEngine;
 import org.txm.searchengine.cqp.clientExceptions.CqiClientException;
@@ -63,103 +64,103 @@
  * @author mdecorde.
  */
 public class ExportCorpusAsFullCoNLLU extends AbstractHandler {
-	
+
 	public static final String ID = ExportCorpusAsFullCoNLLU.class.getName();
-	
+
 	@Option(name = "conlluResultDirectory", usage = "conlluResultDirectory", widget = "Folder", required = true, def = "conllu-result-directory")
 	File conlluResultDirectory;
-	
+
 	@Option(name = "propertiesPrefix", usage = "optional prefix for the properties to create", widget = "String", required = true, def = "ud-")
 	String propertiesPrefix;
-	
+
 	@Option(name = "separator", usage = "Options", widget = "Separator", required = true, def = "comment properties")
 	Boolean separator = false;
-	
+
 	@Option(name = "insertParagraphs", usage = "Insert paragraph marks in the CoNLLU corpus", widget = "Boolean", required = true, def = "true")
 	Boolean insertParagraphs = false;
-	
+
 	@Option(name = "detectGap", usage = "Insert gap comment using the CQP 'gap' property", widget = "Boolean", required = true, def = "true")
 	Boolean detectGap = false;
-	
+
 	@Option(name = "separator3", usage = "Options", widget = "Separator", required = true, def = "tokens options")
 	Boolean separator3 = false;
-	
+
 	@Option(name = "insertNoSpaceAfter", usage = "Insert the NoSpaceAfter misc property if not initially in the CoNLLU corpus", widget = "Boolean", required = true, def = "true")
 	Boolean insertNoSpaceAfter = true;
-	
+
 	@Option(name = "insertTokenWithoutUdAnnotations", usage = "if checked words without ud annotations are exported as well", widget = "Boolean", required = false, def = "false")
 	Boolean insertTokenWithoutUdAnnotations;
-	
+
 	// "form", "lemma", "upos", "xpos", "feats", "head", "deprel", "deps", "misc" };
 	@Option(name = "separator_properties", usage = "Options", widget = "Separator", required = true, def = "fixing UD properties")
 	Boolean separator_properties = false;
-	
+
 	@Option(name = "defaultFormPropertyName", usage = "optional CQP property to fix the missing 'form' ud property", widget = "String", required = false, def = "")
 	String defaultFormPropertyName;
-	
+
 	@Option(name = "defaultLemmaPropertyName", usage = "optional CQP property to fix the missing 'lemma' ud property", widget = "String", required = false, def = "")
 	String defaultLemmaPropertyName;
-	
+
 	@Option(name = "defaultUposPropertyName", usage = "optional CQP property to fix the missing 'upos' ud property", widget = "String", required = false, def = "")
 	String defaultUposPropertyName;
-	
+
 	@Option(name = "defaultXposPropertyName", usage = "optional CQP property to fix the missing 'xpos' ud property", widget = "String", required = false, def = "")
 	String defaultXposPropertyName;
-	
+
 	@Option(name = "defaultFeatsPropertyName", usage = "optional CQP property to fix the missing 'feats' ud property", widget = "String", required = false, def = "")
 	String defaultFeatsPropertyName;
-	
+
 	@Option(name = "defaultHeadPropertyName", usage = "optional CQP property to fix the missing 'head' ud property", widget = "String", required = false, def = "")
 	String defaultHeadPropertyName;
-	
+
 	@Option(name = "defaultDeprelPropertyName", usage = "optional CQP property to fix the missing 'deprel' ud property", widget = "String", required = false, def = "")
 	String defaultDeprelPropertyName;
-	
+
 	@Option(name = "defaultDepsPropertyName", usage = "optional CQP property to fix the missing 'deps' ud property", widget = "String", required = false, def = "")
 	String defaultDepsPropertyName;
-	
+
 	@Option(name = "defaultMiscPropertyName", usage = "optional CQP property to fix the missing 'misc' ud property", widget = "String", required = false, def = "")
 	String defaultMiscPropertyName;
-	
+
 	@Option(name = "separator2", usage = "Options", widget = "Separator", required = true, def = "sentence fix options")
 	Boolean separator2 = false;
-	
+
 	@Option(name = "openingPunct", usage = "optional prefix for the properties to create", widget = "String", required = true, def = "[\\-–«‘“\\(]")
 	String openingPunct;
-	
+
 	/**
 	 * the UD property suffixes, will be used to create the CQP properties like propertiesPrefix + suffix
 	 */
-	public static String[] propNames = { "id", "form", "lemma", "upos", "xpos", "feats", "head", "deprel", "deps", "misc" };
-	
+	public static String[] propNames = ImportCoNLLUAnnotations.UD_PROPERTY_NAMES;
+
 	/*
 	 * (non-Javadoc)
 	 * @see org.eclipse.core.commands.AbstractHandler#execute(org.eclipse.core.commands.ExecutionEvent)
 	 */
 	@Override
 	public Object execute(final ExecutionEvent event) throws ExecutionException {
-		
+
 		IStructuredSelection selection = (IStructuredSelection) HandlerUtil.getCurrentSelection(event);
-		
+
 		Object s = selection.getFirstElement();
 		if (!(s instanceof MainCorpus)) {
 			Log.warning("Selection is not a corpus. Aborting.");
 			return null;
 		}
-		
+
 		if (!ParametersDialog.open(this)) {
 			return null;
 		}
-		
+
 		conlluResultDirectory.mkdirs();
 		if (conlluResultDirectory == null || !conlluResultDirectory.exists() || !conlluResultDirectory.isDirectory()) {
 			Log.warning("Error: conllu result directory does not exists: " + conlluResultDirectory);
 			return null;
 		}
-		
+
 		CQPCorpus corpus = (CQPCorpus) s;
 		MainCorpus mainCorpus = corpus.getMainCorpus();
-		
+
 		try {
 			return exportAnnotationsAsCorpus(mainCorpus, conlluResultDirectory, propertiesPrefix, openingPunct, insertTokenWithoutUdAnnotations,
 					defaultFormPropertyName, defaultLemmaPropertyName, defaultUposPropertyName, defaultXposPropertyName,
@@ -171,10 +172,10 @@
 			Log.warning(e);
 			Log.printStackTrace(e);
 		}
-		
+
 		return null;
 	}
-	
+
 	/**
 	 * export the corpus in a directory of conllu files (one per text)
 	 * 
@@ -202,41 +203,41 @@
 			String defaultFeatsPropertyName, String defaultHeadPropertyName, String defaultDeprelPropertyName, String defaultDepsPropertyName,
 			String defaultMiscPropertyName,
 			boolean detectGap, boolean insertParagraphs, boolean insertNoSpaceAfter)
-			throws UnexpectedAnswerException,
-			IOException,
-			CqiServerError,
-			CqiClientException, InvalidCqpIdException {
-		
+					throws UnexpectedAnswerException,
+					IOException,
+					CqiServerError,
+					CqiClientException, InvalidCqpIdException {
+
 		if (!conlluResultDirectory.exists()) {
 			conlluResultDirectory.mkdirs();
 		}
 		int numberOfWordsWritten = 0;
 		int numberOfSentencesWritten = 0;
 		int numberOfTextsWritten = 0;
-		
+
 		String[] textIds = mainCorpus.getCorpusTextIdsList();
 		int[] start_limits = mainCorpus.getTextStartLimits();
 		int[] end_limits = mainCorpus.getTextEndLimits();
-		
+
 		String lang = mainCorpus.getLang();
 		// HashSet<String> beforeSpacesRules = new HashSet<>(LangFormater.getNoSpaceBefore(mainCorpus.getLang()));
 		// HashSet<String> afterSpacesRules = new HashSet<>(LangFormater.getNoSpaceAfter(mainCorpus.getLang()));
-		
+
 		for (String p : propNames) {
 			WordProperty wp = mainCorpus.getProperty(prefix + p);
 			if (wp == null) {
-				Log.warning("Error: cannot find the Conllu property: " + prefix + p);
-				return 0;
+				Log.warning("Warning: cannot find the Conllu property: " + prefix + p);
+				//return 0;
 			}
 		}
-		
+
 		if (insertTokenWithoutUdAnnotations && (defaultFormPropertyName == null || mainCorpus.getProperty(defaultFormPropertyName) == null)) {
 			Log.warning("Error: the defaultFormPropertyName parameter needs to be set if insertTokenWithoutUdAnnotations is set to true");
 			return 0;
 		}
-		
+
 		for (int iText = 0; iText < start_limits.length; iText++) {
-			
+
 			// Build corpus positions
 			int[] positions = new int[end_limits[iText] - start_limits[iText] + 1];
 			int tmp = 0;
@@ -244,7 +245,7 @@
 				positions[tmp++] = n;
 			}
 			numberOfWordsWritten += positions.length;
-			
+
 			// Get UD properties
 			WordProperty wp;
 			wp = mainCorpus.getProperty(prefix + "id");
@@ -259,27 +260,58 @@
 				}
 			}
 			tmpValues = null;
-			
-			WordProperty formWordProperty = mainCorpus.getProperty(prefix + "form");
-			String[] formValues = CQPSearchEngine.getCqiClient().cpos2Str(formWordProperty.getQualifiedName(), positions);
-			fixUNDEFValues(formValues);
-			
+
+			String[] emptyvalues = new String[positions.length];
+			for (int i = 0 ; i < emptyvalues.length ; i++) {
+				emptyvalues[i] = "_";
+			}
+
+			wp = mainCorpus.getProperty(prefix + "form");
+			String[] formValues = null;
+			if (wp != null) {
+				formValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
+				fixUNDEFValues(formValues);
+			} else {
+				formValues = emptyvalues;
+			}
+
+
 			wp = mainCorpus.getProperty(prefix + "lemma");
-			String[] lemmaValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
-			fixUNDEFValues(lemmaValues);
-			
+			String[] lemmaValues = null;
+			if (wp != null) {
+				lemmaValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
+				fixUNDEFValues(lemmaValues);
+			} else {
+				lemmaValues = emptyvalues;
+			}
+
 			wp = mainCorpus.getProperty(prefix + "upos");
-			String[] uposValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
-			fixUNDEFValues(uposValues);
-			
+			String[] uposValues = null;
+			if (wp != null) {
+				uposValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
+				fixUNDEFValues(uposValues);
+			} else {
+				uposValues = emptyvalues;
+			}
+
 			wp = mainCorpus.getProperty(prefix + "xpos");
-			String[] xposValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
-			fixUNDEFValues(xposValues);
-			
+			String[] xposValues = null;
+			if (wp != null) {
+				xposValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
+				fixUNDEFValues(xposValues);
+			} else {
+				xposValues = emptyvalues;
+			}
+
 			wp = mainCorpus.getProperty(prefix + "feats");
-			String[] featsValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
-			fixUNDEFValues(featsValues);
-			
+			String[] featsValues = null;
+			if (wp != null) {
+				featsValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
+				fixUNDEFValues(featsValues);
+			} else {
+				featsValues = emptyvalues;
+			}
+
 			wp = mainCorpus.getProperty(prefix + "head");
 			// String[] headValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
 			tmpValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
@@ -293,19 +325,34 @@
 				}
 			}
 			tmpValues = null;
-			
+
 			wp = mainCorpus.getProperty(prefix + "deprel");
-			String[] deprelValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
-			fixUNDEFValues(deprelValues);
-			
+			String[] deprelValues = null;
+			if (wp != null) {
+				deprelValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
+				fixUNDEFValues(deprelValues);
+			} else {
+				deprelValues = emptyvalues;
+			}
+
 			wp = mainCorpus.getProperty(prefix + "deps");
-			String[] depsValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
-			fixUNDEFValues(depsValues);
-			
+			String[] depsValues = null;
+			if (wp != null) {
+				depsValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
+				fixUNDEFValues(depsValues);
+			} else {
+				depsValues = emptyvalues;
+			}
+
 			wp = mainCorpus.getProperty(prefix + "misc");
-			String[] miscValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
-			fixUNDEFValues(miscValues);
-			
+			String[] miscValues = null;
+			if (wp != null) {
+				miscValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
+				fixUNDEFValues(miscValues);
+			} else {
+				miscValues = emptyvalues;
+			}
+
 			HashSet<Integer> paragraphsStartPositions = new HashSet<>();
 			if (insertParagraphs) {
 				StructuralUnit p_struct = mainCorpus.getStructuralUnit("p");
@@ -319,10 +366,10 @@
 					}
 				}
 			}
-			
+
 			HashMap<Integer, String> sentidStartPositions = getNonUNDEFPositionsAndValues(mainCorpus, prefix+"sentid");
 			HashMap<Integer, String> newdocidStartPositions = getNonUNDEFPositionsAndValues(mainCorpus, prefix+"newdocid");
-			
+
 			// build sentence, first pass using UD word sentence positions
 			ArrayList<ArrayList<Integer>> sentences = new ArrayList<>();
 			ArrayList<Integer> tmpSentence = new ArrayList<>();
@@ -331,38 +378,38 @@
 				// + featsValues[p] + " head="
 				// + headValues[p] + " deprel=" + deprelValues[p] + " deps=" + depsValues[p] + " misc=" + miscValues[p]);
 				if (sentidStartPositions.containsKey(p)) { // new ud sentence
-					
+
 					if (tmpSentence.size() > 0) {
 						sentences.add(new ArrayList<>(tmpSentence));
 					}
-					
+
 					// System.out.println("new sentence: " + " id=" + idValues[p] + " form=" + formValues[p] + " lemma=" + lemmaValues[p] + " upos=" + uposValues[p] + " xpos=" + xposValues[p] + "
 					// feats="
 					// + featsValues[p] + " head="
 					// + headValues[p] + " deprel=" + deprelValues[p] + " deps=" + depsValues[p] + " misc=" + miscValues[p]);
 					tmpSentence.clear();
 				}
-				
+
 				if (insertTokenWithoutUdAnnotations) {
 					tmpSentence.add(p); // insert all tokens
 				}
 				else if (idValues[p] != 0) {
 					tmpSentence.add(p); // insert all tokens
 				}
-				
+
 			}
 			positions = null; // free memory
-			
+
 			// fixing sentences
 			for (int s = 0; s < sentences.size(); s++) {
-				
+
 				// fix only ud sentences limits
 				ArrayList<Integer> sentence = sentences.get(s);
-				
+
 				if (sentidStartPositions.get(sentence.get(0)) == null) {
 					continue; // this is not a UD sentence
 				}
-				
+
 				int max = -1;
 				int imax = 0;
 				for (int ip = 0; ip < sentence.size(); ip++) {
@@ -372,7 +419,7 @@
 						imax = ip;
 					}
 				}
-				
+
 				ArrayList<Integer> newSentence = new ArrayList<>();
 				for (int ip = imax + 1; ip < sentence.size(); ip++) {
 					newSentence.add(sentence.get(ip));
@@ -388,23 +435,23 @@
 					sentences.add(s + 1, newSentence);
 				}
 			}
-			
+
 			if (tmpSentence.size() > 0) { // add last sentence
 				sentences.add(new ArrayList<>(tmpSentence));
 			}
-			
+
 			// fixing sentence __NULL__ ud properties
 			for (int iSentence = 0; iSentence < sentences.size(); iSentence++) {
 				ArrayList<Integer> sentence = sentences.get(iSentence);
-				
+
 				int[] sentencePositions = new int[sentence.size()];
 				for (int p = 0; p < sentence.size(); p++) {
 					sentencePositions[p] = sentence.get(p);
 				}
-				
+
 				// get CQP values fixing "form", "lemma", "upos", "xpos", "feats", "head", "deprel", "deps"
 				String[] ids = CQPSearchEngine.getCqiClient().cpos2Str(mainCorpus.getProperty("id").getQualifiedName(), sentencePositions);
-				
+
 				String[] words = null;
 				if (defaultFormPropertyName != null && defaultFormPropertyName.length() > 0) {
 					words = getDefaultValues(mainCorpus, defaultFormPropertyName, sentencePositions);
@@ -421,7 +468,7 @@
 				if (defaultXposPropertyName != null && defaultXposPropertyName.length() > 0) {
 					xposs = getDefaultValues(mainCorpus, defaultXposPropertyName, sentencePositions);
 				}
-				
+
 				String[] feats = null;
 				if (defaultFeatsPropertyName != null && defaultFeatsPropertyName.length() > 0) {
 					feats = getDefaultValues(mainCorpus, defaultFeatsPropertyName, sentencePositions);
@@ -442,22 +489,22 @@
 				if (defaultMiscPropertyName != null && defaultMiscPropertyName.length() > 0) {
 					miscs = getDefaultValues(mainCorpus, defaultMiscPropertyName, sentencePositions);
 				}
-				
+
 				// String[] feats = CQPSearchEngine.getCqiClient().cpos2Str(mainCorpus.getProperty(featsCorrPropertyName).getQualifiedName(), sentencePositions);
 				// String[] head = CQPSearchEngine.getCqiClient().cpos2Str(mainCorpus.getProperty(headCorrPropertyName).getQualifiedName(), sentencePositions);
 				// String[] deprel = CQPSearchEngine.getCqiClient().cpos2Str(mainCorpus.getProperty(deprelCorrPropertyName).getQualifiedName(), sentencePositions);
 				// String[] deps = CQPSearchEngine.getCqiClient().cpos2Str(mainCorpus.getProperty(deprelCorrPropertyName).getQualifiedName(), sentencePositions);
-				
+
 				// fix ud properties using CQP values
 				for (int ip = 0; ip < sentence.size(); ip++) {
-					
+
 					int p = sentence.get(ip);
-					
+
 					// new word
 					if (miscValues[p].equals("_")) {
 						miscValues[p] = "XmlId=" + ids[ip];
 					}
-					
+
 					// { "id", "form", "lemma", "upos", "xpos", "feats", "head", "deprel", "deps", "misc" };
 					if (words != null && formValues[p].equals("_")) {
 						formValues[p] = words[ip];
@@ -487,7 +534,7 @@
 						miscValues[p] = miscs[ip];
 					}
 				}
-				
+
 				if (insertNoSpaceAfter) {
 					for (int ip = 0; ip < sentence.size(); ip++) { // fix SpaceAfter. !!! this needs to be done after ud properties are fixed
 						int p = sentence.get(ip);
@@ -503,7 +550,7 @@
 						}
 					}
 				}
-				
+
 				// fixing sentence punct limits
 				while (sentence.size() > 0 && iSentence > 0 && formValues[sentence.get(0)].matches("\\p{P}") && !formValues[sentence.get(0)].matches(openingPunct)) {
 					// System.out.println("FIXING: first non-openingPunct position " + formValues[sentence.get(0)] + " in " + iSentence);
@@ -516,34 +563,34 @@
 					int p2 = sentence.remove(sentence.size() - 1);
 					sentences.get(iSentence + 1).add(0, p2);
 				}
-				
+
 				if (sentence.size() == 0) { // sentence was depleted after fixing it
 					sentences.remove(iSentence);
 					iSentence--;
 					continue;
 				}
 			}
-			
+
 			for (int s = 0; s < sentences.size(); s++) {
-				
+
 				// fix only ud sentences limits
 				ArrayList<Integer> sentence = sentences.get(s);
 				HashMap<Integer, Integer> oldToNewIds = new HashMap<>();
 				for (int ip = 0; ip < sentence.size(); ip++) { // computing old to new ids
 					int p = sentence.get(ip);
-					
+
 					if (idValues[p] != 0) { // store "old id -> new id"
 						oldToNewIds.put(idValues[p], (ip + 1)); // from 1 to N
 					}
 				}
-				
+
 				// fixing head and set missing head to 0 and root
 				for (int ip = 0; ip < sentence.size(); ip++) {
 					int p = sentence.get(ip);
-					
+
 					// fixing id value
 					idValues[p] = (ip + 1);  // from 1 to N
-					
+
 					// fixing head values
 					if (oldToNewIds.containsKey(headValues[p])) {
 						headValues[p] = oldToNewIds.get(headValues[p]);
@@ -555,45 +602,45 @@
 					}
 				}
 			}
-			
+
 			// writing sentences
 			File resultConlluFile = new File(conlluResultDirectory, textIds[iText] + ".conllu");
 			PrintWriter writer = IOUtils.getWriter(resultConlluFile);
-			
+
 			int iParagraph = 1;
-			
+
 			for (int iSentence = 0; iSentence < sentences.size(); iSentence++) {
 				ArrayList<Integer> sentence = sentences.get(iSentence);
-				
+
 				int[] sentencePositions = new int[sentence.size()];
 				for (int p = 0; p < sentence.size(); p++) {
 					sentencePositions[p] = sentence.get(p);
 				}
-				
+
 				String[] gap = null;
 				if (detectGap && mainCorpus.getProperty("gap") != null) {
 					gap = CQPSearchEngine.getCqiClient().cpos2Str(mainCorpus.getProperty("gap").getQualifiedName(), sentencePositions);
 				}
-				
+
 				String[] tokens = new String[sentence.size()];
 				for (int ip = 0; ip < sentence.size(); ip++) {
 					tokens[ip] = formValues[sentence.get(ip)];
 				}
-				
+
 				if (insertNoSpaceAfter) {
 					writer.println("# text = " + LangFormater.format(StringUtils.join(tokens, " "), mainCorpus.getLang()));
 				}
 				else {
 					writer.println("# text = " + StringUtils.join(tokens, " "));
 				}
-				
+
 				if (newdocidStartPositions.containsKey(sentence.get(0))) {
 					writer.println("# newdoc id = " + newdocidStartPositions.get(sentence.get(0)));
 				}
 				else {
 					writer.println("# newdoc id = " + textIds[iText]);
 				}
-				
+
 				boolean foundSentId = false;
 				for (int ip : sentence) {
 					if (!foundSentId && sentidStartPositions.containsKey(ip)) {
@@ -604,20 +651,20 @@
 				if (!foundSentId) { // no sent_id found
 					writer.println("# sent_id = " + textIds[iText] + "-" + (iSentence + 1) + ".new");
 				}
-				
+
 				if (paragraphsStartPositions.contains(sentence.get(0))) { // paragraphsStartPositions is empty if the injectParagraph option is not set
 					writer.println("# newpar id = " + iParagraph);
 					iParagraph++;
 				}
-				
+
 				for (int ip = 0; ip < sentence.size(); ip++) {
 					int p = sentence.get(ip);
-					
+
 					// { "id", "form", "lemma", "upos", "xpos", "feats", "head", "deprel", "deps", "misc" };
 					writer.println(idValues[p] + "\t" + formValues[p] + "\t" + lemmaValues[p] + "\t" + uposValues[p]
 							+ "\t" + xposValues[p] + "\t" + featsValues[p] + "\t" + headValues[p] + "\t" + deprelValues[p]
-							+ "\t" + depsValues[p] + "\t" + miscValues[p]);
-					
+									+ "\t" + depsValues[p] + "\t" + miscValues[p]);
+
 					if (gap != null && gap[ip].equals("next")) {
 						writer.println("# gap");
 					}
@@ -626,48 +673,51 @@
 				numberOfSentencesWritten++;
 			}
 			writer.close();
-			
+
 			System.out.println(" Text done: " + resultConlluFile);
 			numberOfTextsWritten++;
 		}
-		
+
 		System.out.println("# words written: " + numberOfWordsWritten);
 		System.out.println("# sentences written: " + numberOfSentencesWritten);
 		System.out.println("# texts written: " + numberOfTextsWritten);
-		
+
 		return numberOfWordsWritten;
 	}
-	
+
 	private static String[] getDefaultValues(MainCorpus mainCorpus, String property, int[] positions) throws UnexpectedAnswerException, IOException, CqiServerError, CqiClientException {
-		
+
 		String[] values = CQPSearchEngine.getCqiClient().cpos2Str(mainCorpus.getProperty(property).getQualifiedName(), positions);
 		for (int iupos = 0; iupos < values.length; iupos++) { // recode the || CQP multiple values to ud multiple values
 			if (values[iupos].length() > 2 && values[iupos].startsWith("|") && values[iupos].endsWith("|")) {
 				values[iupos] = values[iupos].substring(1, values[iupos].length() - 1);
 			}
 		}
-		
+
 		return values;
 	}
-	
+
 	private static HashMap<Integer, String> getNonUNDEFPositionsAndValues(MainCorpus mainCorpus, String property) throws UnexpectedAnswerException, IOException, CqiServerError, CqiClientException {
-		
+
+
+
 		HashMap<Integer, String> sentidStartPositions = new HashMap<>();
-		int[] ids = CQPSearchEngine.getCqiClient().regex2Id(mainCorpus.getProperty(property).getQualifiedName(), "(?!__UNDEF__).+");
-		String[] strs = CQPSearchEngine.getCqiClient().id2Str(mainCorpus.getProperty(property).getQualifiedName(), ids);
-		for (int iId = 0; iId < ids.length; iId++) {
-			int id = ids[iId];
-			int[] pp = CQPSearchEngine.getCqiClient().id2Cpos(mainCorpus.getProperty(property).getQualifiedName(), id);
-			for (int p : pp) {
-				sentidStartPositions.put(p, strs[iId]);
+		if (mainCorpus.getProperty(property) != null) {
+			int[] ids = CQPSearchEngine.getCqiClient().regex2Id(mainCorpus.getProperty(property).getQualifiedName(), "(?!__UNDEF__).+");
+			String[] strs = CQPSearchEngine.getCqiClient().id2Str(mainCorpus.getProperty(property).getQualifiedName(), ids);
+			for (int iId = 0; iId < ids.length; iId++) {
+				int id = ids[iId];
+				int[] pp = CQPSearchEngine.getCqiClient().id2Cpos(mainCorpus.getProperty(property).getQualifiedName(), id);
+				for (int p : pp) {
+					sentidStartPositions.put(p, strs[iId]);
+				}
 			}
 		}
-		
 		return sentidStartPositions;
 	}
-	
+
 	private static void fixUNDEFValues(String[] values) {
-		
+
 		for (int i = 0; i < values.length; i++) {
 			if (values[i].equals("__UNDEF__") || values[i].equals("") || values[i].equals("|_|")) {
 				values[i] = "_";
Index: TXM/trunk/bundles/org.txm.conllu.rcp/src/org/txm/conllu/rcp/commands/ToCoNLL2009.java
===================================================================
--- TXM/trunk/bundles/org.txm.conllu.rcp/src/org/txm/conllu/rcp/commands/ToCoNLL2009.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.conllu.rcp/src/org/txm/conllu/rcp/commands/ToCoNLL2009.java	(revision 3731)
@@ -12,15 +12,13 @@
 import org.txm.searchengine.cqp.corpus.CorpusManager;
 import org.txm.searchengine.cqp.corpus.Property;
 import org.txm.searchengine.cqp.corpus.StructuralUnit;
-import org.txm.searchengine.cqp.corpus.StructuralUnitProperty;
 import org.txm.searchengine.cqp.corpus.WordProperty;
 import org.txm.searchengine.cqp.corpus.query.CQLQuery;
 import org.txm.searchengine.cqp.corpus.query.Match;
 import org.txm.searchengine.cqp.serverException.CqiServerError;
 import org.txm.utils.ConsoleProgressBar;
+import org.txm.utils.logger.Log;
 
-import jline.internal.Log;
-
 public class ToCoNLL2009 {
 	
 	boolean debug = false;
Index: TXM/trunk/bundles/org.txm.conllu.rcp/src/org/txm/conllu/rcp/commands/ExportCorpusAsCoNLLU.java
===================================================================
--- TXM/trunk/bundles/org.txm.conllu.rcp/src/org/txm/conllu/rcp/commands/ExportCorpusAsCoNLLU.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.conllu.rcp/src/org/txm/conllu/rcp/commands/ExportCorpusAsCoNLLU.java	(revision 3731)
@@ -42,6 +42,7 @@
 import org.eclipse.osgi.util.NLS;
 import org.eclipse.ui.handlers.HandlerUtil;
 import org.kohsuke.args4j.Option;
+import org.txm.conllu.core.function.ImportCoNLLUAnnotations;
 import org.txm.rcp.swt.widget.parameters.ParametersDialog;
 import org.txm.searchengine.cqp.CQPSearchEngine;
 import org.txm.searchengine.cqp.clientExceptions.CqiClientException;
@@ -63,65 +64,65 @@
  * @author mdecorde.
  */
 public class ExportCorpusAsCoNLLU extends AbstractHandler {
-	
+
 	public static final String ID = ExportCorpusAsCoNLLU.class.getName();
-	
+
 	@Option(name="outputDirectory", usage="an example file", widget="Folder", required=true, def="outputDirectory")
 	File outputDirectory;
-	
+
 	@Option(name="encoding", usage="sentenceProperty", widget="String", required=true, def="UTF-8")
 	String encoding = "UTF-8";
 
-	 @Option(name="sentenceStructure", usage="sentenceProperty", widget="String", required=true, def="s")
+	@Option(name="sentenceStructure", usage="sentenceProperty", widget="String", required=true, def="s")
 	String sentenceStructure;
-	
+
 	@Option(name="posProperty", usage="if set posProperty used to fill the UPOS ud property", widget="String", required=true, def="frpos")
 	String posProperty;
-	
+
 	@Option(name="lemmaProperty", usage="if set lemmaProperty used to fill the LEMMA ud property", widget="String", required=true, def="frlemma")
 	String lemmaProperty;
-	
+
 	/**
 	 * the UD property suffixes, will be used to create the CQP properties like propertiesPrefix + suffix
 	 */
-	public static String[] propNames = { "id", "form", "lemma", "upos", "xpos", "feats", "head", "deprel", "deps", "misc" };
-	
+	public static String[] propNames = ImportCoNLLUAnnotations.UD_PROPERTY_NAMES;
+
 	/*
 	 * (non-Javadoc)
 	 * @see org.eclipse.core.commands.AbstractHandler#execute(org.eclipse.core.commands.ExecutionEvent)
 	 */
 	@Override
 	public Object execute(final ExecutionEvent event) throws ExecutionException {
-		
+
 		IStructuredSelection selection = (IStructuredSelection) HandlerUtil.getCurrentSelection(event);
-		
+
 		Object s = selection.getFirstElement();
 		if (!(s instanceof MainCorpus)) {
 			Log.warning("Selection is not a corpus. Aborting.");
 			return null;
 		}
-		
+
 		if (!ParametersDialog.open(this)) {
 			return null;
 		}
-		
+
 		outputDirectory.mkdirs();
 		if (outputDirectory == null || !outputDirectory.exists() || !outputDirectory.isDirectory()) {
 			Log.warning("Error: conllu result directory does not exists: " + outputDirectory);
 			return null;
 		}
-		
+
 		CQPCorpus corpus = (CQPCorpus) s;
 		MainCorpus mainCorpus = corpus.getMainCorpus();
-		
+
 		return exportCorpus(mainCorpus, outputDirectory, sentenceStructure, lemmaProperty, posProperty, encoding);
-		
+
 	}
-	
+
 	public static boolean exportCorpus(MainCorpus mainCorpus, File outputDirectory, String sentenceStructure, String lemmaProperty, String posProperty, String encoding) {
 		try {
 			return new ToCoNLL2009().process(outputDirectory, mainCorpus, mainCorpus.getStructuralUnit(sentenceStructure), mainCorpus.getProperty("word"), mainCorpus.getProperty(lemmaProperty), mainCorpus.getProperty(posProperty), encoding);
-			
+
 		} catch (Exception e) {
 			Log.warning(e);
 			Log.printStackTrace(e);
@@ -156,41 +157,41 @@
 			String defaultFeatsPropertyName, String defaultHeadPropertyName, String defaultDeprelPropertyName, String defaultDepsPropertyName,
 			String defaultMiscPropertyName,
 			boolean detectGap, boolean insertParagraphs, boolean insertNoSpaceAfter)
-			throws UnexpectedAnswerException,
-			IOException,
-			CqiServerError,
-			CqiClientException, InvalidCqpIdException {
-		
+					throws UnexpectedAnswerException,
+					IOException,
+					CqiServerError,
+					CqiClientException, InvalidCqpIdException {
+
 		if (!conlluResultDirectory.exists()) {
 			conlluResultDirectory.mkdirs();
 		}
 		int numberOfWordsWritten = 0;
 		int numberOfSentencesWritten = 0;
 		int numberOfTextsWritten = 0;
-		
+
 		String[] textIds = mainCorpus.getCorpusTextIdsList();
 		int[] start_limits = mainCorpus.getTextStartLimits();
 		int[] end_limits = mainCorpus.getTextEndLimits();
-		
+
 		String lang = mainCorpus.getLang();
 		// HashSet<String> beforeSpacesRules = new HashSet<>(LangFormater.getNoSpaceBefore(mainCorpus.getLang()));
 		// HashSet<String> afterSpacesRules = new HashSet<>(LangFormater.getNoSpaceAfter(mainCorpus.getLang()));
-		
+
 		for (String p : propNames) {
 			WordProperty wp = mainCorpus.getProperty(prefix + p);
 			if (wp == null) {
-				Log.warning("Error: cannot find the Conllu property: " + prefix + p);
+				Log.warning("Error: cannot find the CoNLLU property: " + prefix + p);
 				return 0;
 			}
 		}
-		
+
 		if (insertTokenWithoutUdAnnotations && (defaultFormPropertyName == null || mainCorpus.getProperty(defaultFormPropertyName) == null)) {
 			Log.warning("Error: the defaultFormPropertyName parameter needs to be set if insertTokenWithoutUdAnnotations is set to true");
 			return 0;
 		}
-		
+
 		for (int iText = 0; iText < start_limits.length; iText++) {
-			
+
 			// Build corpus positions
 			int[] positions = new int[end_limits[iText] - start_limits[iText] + 1];
 			int tmp = 0;
@@ -198,7 +199,7 @@
 				positions[tmp++] = n;
 			}
 			numberOfWordsWritten += positions.length;
-			
+
 			// Get UD properties
 			WordProperty wp;
 			wp = mainCorpus.getProperty(prefix + "id");
@@ -213,27 +214,27 @@
 				}
 			}
 			tmpValues = null;
-			
+
 			WordProperty formWordProperty = mainCorpus.getProperty(prefix + "form");
 			String[] formValues = CQPSearchEngine.getCqiClient().cpos2Str(formWordProperty.getQualifiedName(), positions);
 			fixUNDEFValues(formValues);
-			
+
 			wp = mainCorpus.getProperty(prefix + "lemma");
 			String[] lemmaValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
 			fixUNDEFValues(lemmaValues);
-			
+
 			wp = mainCorpus.getProperty(prefix + "upos");
 			String[] uposValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
 			fixUNDEFValues(uposValues);
-			
+
 			wp = mainCorpus.getProperty(prefix + "xpos");
 			String[] xposValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
 			fixUNDEFValues(xposValues);
-			
+
 			wp = mainCorpus.getProperty(prefix + "feats");
 			String[] featsValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
 			fixUNDEFValues(featsValues);
-			
+
 			wp = mainCorpus.getProperty(prefix + "head");
 			// String[] headValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
 			tmpValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
@@ -247,19 +248,19 @@
 				}
 			}
 			tmpValues = null;
-			
+
 			wp = mainCorpus.getProperty(prefix + "deprel");
 			String[] deprelValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
 			fixUNDEFValues(deprelValues);
-			
+
 			wp = mainCorpus.getProperty(prefix + "deps");
 			String[] depsValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
 			fixUNDEFValues(depsValues);
-			
+
 			wp = mainCorpus.getProperty(prefix + "misc");
 			String[] miscValues = CQPSearchEngine.getCqiClient().cpos2Str(wp.getQualifiedName(), positions);
 			fixUNDEFValues(miscValues);
-			
+
 			HashSet<Integer> paragraphsStartPositions = new HashSet<>();
 			if (insertParagraphs) {
 				StructuralUnit p_struct = mainCorpus.getStructuralUnit("p");
@@ -273,50 +274,43 @@
 					}
 				}
 			}
-			
+
 			HashMap<Integer, String> sentidStartPositions = getNonUNDEFPositionsAndValues(mainCorpus, prefix+"sentid");
 			HashMap<Integer, String> newdocidStartPositions = getNonUNDEFPositionsAndValues(mainCorpus, prefix+"newdocid");
-			
+
 			// build sentence, first pass using UD word sentence positions
 			ArrayList<ArrayList<Integer>> sentences = new ArrayList<>();
 			ArrayList<Integer> tmpSentence = new ArrayList<>();
 			for (int p = 0; p < positions.length; p++) {
-				// System.out.println("p=" + p + " id=" + idValues[p] + " form=" + formValues[p] + " lemma=" + lemmaValues[p] + " upos=" + uposValues[p] + " xpos=" + xposValues[p] + " feats="
-				// + featsValues[p] + " head="
-				// + headValues[p] + " deprel=" + deprelValues[p] + " deps=" + depsValues[p] + " misc=" + miscValues[p]);
 				if (sentidStartPositions.containsKey(p)) { // new ud sentence
-					
+
 					if (tmpSentence.size() > 0) {
 						sentences.add(new ArrayList<>(tmpSentence));
 					}
-					
-					// System.out.println("new sentence: " + " id=" + idValues[p] + " form=" + formValues[p] + " lemma=" + lemmaValues[p] + " upos=" + uposValues[p] + " xpos=" + xposValues[p] + "
-					// feats="
-					// + featsValues[p] + " head="
-					// + headValues[p] + " deprel=" + deprelValues[p] + " deps=" + depsValues[p] + " misc=" + miscValues[p]);
+
 					tmpSentence.clear();
 				}
-				
+
 				if (insertTokenWithoutUdAnnotations) {
 					tmpSentence.add(p); // insert all tokens
 				}
 				else if (idValues[p] != 0) {
 					tmpSentence.add(p); // insert all tokens
 				}
-				
+
 			}
 			positions = null; // free memory
-			
+
 			// fixing sentences
 			for (int s = 0; s < sentences.size(); s++) {
-				
+
 				// fix only ud sentences limits
 				ArrayList<Integer> sentence = sentences.get(s);
-				
+
 				if (sentidStartPositions.get(sentence.get(0)) == null) {
 					continue; // this is not a UD sentence
 				}
-				
+
 				int max = -1;
 				int imax = 0;
 				for (int ip = 0; ip < sentence.size(); ip++) {
@@ -326,7 +320,7 @@
 						imax = ip;
 					}
 				}
-				
+
 				ArrayList<Integer> newSentence = new ArrayList<>();
 				for (int ip = imax + 1; ip < sentence.size(); ip++) {
 					newSentence.add(sentence.get(ip));
@@ -342,23 +336,23 @@
 					sentences.add(s + 1, newSentence);
 				}
 			}
-			
+
 			if (tmpSentence.size() > 0) { // add last sentence
 				sentences.add(new ArrayList<>(tmpSentence));
 			}
-			
+
 			// fixing sentence __NULL__ ud properties
 			for (int iSentence = 0; iSentence < sentences.size(); iSentence++) {
 				ArrayList<Integer> sentence = sentences.get(iSentence);
-				
+
 				int[] sentencePositions = new int[sentence.size()];
 				for (int p = 0; p < sentence.size(); p++) {
 					sentencePositions[p] = sentence.get(p);
 				}
-				
+
 				// get CQP values fixing "form", "lemma", "upos", "xpos", "feats", "head", "deprel", "deps"
 				String[] ids = CQPSearchEngine.getCqiClient().cpos2Str(mainCorpus.getProperty("id").getQualifiedName(), sentencePositions);
-				
+
 				String[] words = null;
 				if (defaultFormPropertyName != null && defaultFormPropertyName.length() > 0) {
 					words = getDefaultValues(mainCorpus, defaultFormPropertyName, sentencePositions);
@@ -375,7 +369,7 @@
 				if (defaultXposPropertyName != null && defaultXposPropertyName.length() > 0) {
 					xposs = getDefaultValues(mainCorpus, defaultXposPropertyName, sentencePositions);
 				}
-				
+
 				String[] feats = null;
 				if (defaultFeatsPropertyName != null && defaultFeatsPropertyName.length() > 0) {
 					feats = getDefaultValues(mainCorpus, defaultFeatsPropertyName, sentencePositions);
@@ -396,22 +390,22 @@
 				if (defaultMiscPropertyName != null && defaultMiscPropertyName.length() > 0) {
 					miscs = getDefaultValues(mainCorpus, defaultMiscPropertyName, sentencePositions);
 				}
-				
+
 				// String[] feats = CQPSearchEngine.getCqiClient().cpos2Str(mainCorpus.getProperty(featsCorrPropertyName).getQualifiedName(), sentencePositions);
 				// String[] head = CQPSearchEngine.getCqiClient().cpos2Str(mainCorpus.getProperty(headCorrPropertyName).getQualifiedName(), sentencePositions);
 				// String[] deprel = CQPSearchEngine.getCqiClient().cpos2Str(mainCorpus.getProperty(deprelCorrPropertyName).getQualifiedName(), sentencePositions);
 				// String[] deps = CQPSearchEngine.getCqiClient().cpos2Str(mainCorpus.getProperty(deprelCorrPropertyName).getQualifiedName(), sentencePositions);
-				
+
 				// fix ud properties using CQP values
 				for (int ip = 0; ip < sentence.size(); ip++) {
-					
+
 					int p = sentence.get(ip);
-					
+
 					// new word
 					if (miscValues[p].equals("_")) {
 						miscValues[p] = "XmlId=" + ids[ip];
 					}
-					
+
 					// { "id", "form", "lemma", "upos", "xpos", "feats", "head", "deprel", "deps", "misc" };
 					if (words != null && formValues[p].equals("_")) {
 						formValues[p] = words[ip];
@@ -441,7 +435,7 @@
 						miscValues[p] = miscs[ip];
 					}
 				}
-				
+
 				if (insertNoSpaceAfter) {
 					for (int ip = 0; ip < sentence.size(); ip++) { // fix SpaceAfter. !!! this needs to be done after ud properties are fixed
 						int p = sentence.get(ip);
@@ -457,7 +451,7 @@
 						}
 					}
 				}
-				
+
 				// fixing sentence punct limits
 				while (sentence.size() > 0 && iSentence > 0 && formValues[sentence.get(0)].matches("\\p{P}") && !formValues[sentence.get(0)].matches(openingPunct)) {
 					// System.out.println("FIXING: first non-openingPunct position " + formValues[sentence.get(0)] + " in " + iSentence);
@@ -470,34 +464,34 @@
 					int p2 = sentence.remove(sentence.size() - 1);
 					sentences.get(iSentence + 1).add(0, p2);
 				}
-				
+
 				if (sentence.size() == 0) { // sentence was depleted after fixing it
 					sentences.remove(iSentence);
 					iSentence--;
 					continue;
 				}
 			}
-			
+
 			for (int s = 0; s < sentences.size(); s++) {
-				
+
 				// fix only ud sentences limits
 				ArrayList<Integer> sentence = sentences.get(s);
 				HashMap<Integer, Integer> oldToNewIds = new HashMap<>();
 				for (int ip = 0; ip < sentence.size(); ip++) { // computing old to new ids
 					int p = sentence.get(ip);
-					
+
 					if (idValues[p] != 0) { // store "old id -> new id"
 						oldToNewIds.put(idValues[p], (ip + 1)); // from 1 to N
 					}
 				}
-				
+
 				// fixing head and set missing head to 0 and root
 				for (int ip = 0; ip < sentence.size(); ip++) {
 					int p = sentence.get(ip);
-					
+
 					// fixing id value
 					idValues[p] = (ip + 1);  // from 1 to N
-					
+
 					// fixing head values
 					if (oldToNewIds.containsKey(headValues[p])) {
 						headValues[p] = oldToNewIds.get(headValues[p]);
@@ -509,45 +503,45 @@
 					}
 				}
 			}
-			
+
 			// writing sentences
 			File resultConlluFile = new File(conlluResultDirectory, textIds[iText] + ".conllu");
 			PrintWriter writer = IOUtils.getWriter(resultConlluFile);
-			
+
 			int iParagraph = 1;
-			
+
 			for (int iSentence = 0; iSentence < sentences.size(); iSentence++) {
 				ArrayList<Integer> sentence = sentences.get(iSentence);
-				
+
 				int[] sentencePositions = new int[sentence.size()];
 				for (int p = 0; p < sentence.size(); p++) {
 					sentencePositions[p] = sentence.get(p);
 				}
-				
+
 				String[] gap = null;
 				if (detectGap && mainCorpus.getProperty("gap") != null) {
 					gap = CQPSearchEngine.getCqiClient().cpos2Str(mainCorpus.getProperty("gap").getQualifiedName(), sentencePositions);
 				}
-				
+
 				String[] tokens = new String[sentence.size()];
 				for (int ip = 0; ip < sentence.size(); ip++) {
 					tokens[ip] = formValues[sentence.get(ip)];
 				}
-				
+
 				if (insertNoSpaceAfter) {
 					writer.println("# text = " + LangFormater.format(StringUtils.join(tokens, " "), mainCorpus.getLang()));
 				}
 				else {
 					writer.println("# text = " + StringUtils.join(tokens, " "));
 				}
-				
+
 				if (newdocidStartPositions.containsKey(sentence.get(0))) {
 					writer.println("# newdoc id = " + newdocidStartPositions.get(sentence.get(0)));
 				}
 				else {
 					writer.println("# newdoc id = " + textIds[iText]);
 				}
-				
+
 				boolean foundSentId = false;
 				for (int ip : sentence) {
 					if (!foundSentId && sentidStartPositions.containsKey(ip)) {
@@ -558,20 +552,20 @@
 				if (!foundSentId) { // no sent_id found
 					writer.println("# sent_id = " + textIds[iText] + "-" + (iSentence + 1) + ".new");
 				}
-				
+
 				if (paragraphsStartPositions.contains(sentence.get(0))) { // paragraphsStartPositions is empty if the injectParagraph option is not set
 					writer.println("# newpar id = " + iParagraph);
 					iParagraph++;
 				}
-				
+
 				for (int ip = 0; ip < sentence.size(); ip++) {
 					int p = sentence.get(ip);
-					
+
 					// { "id", "form", "lemma", "upos", "xpos", "feats", "head", "deprel", "deps", "misc" };
 					writer.println(idValues[p] + "\t" + formValues[p] + "\t" + lemmaValues[p] + "\t" + uposValues[p]
 							+ "\t" + xposValues[p] + "\t" + featsValues[p] + "\t" + headValues[p] + "\t" + deprelValues[p]
-							+ "\t" + depsValues[p] + "\t" + miscValues[p]);
-					
+									+ "\t" + depsValues[p] + "\t" + miscValues[p]);
+
 					if (gap != null && gap[ip].equals("next")) {
 						writer.println("# gap");
 					}
@@ -580,32 +574,40 @@
 				numberOfSentencesWritten++;
 			}
 			writer.close();
-			
+
 			System.out.println(" Text done: " + resultConlluFile);
 			numberOfTextsWritten++;
 		}
-		
+
 		System.out.println("# words written: " + numberOfWordsWritten);
 		System.out.println("# sentences written: " + numberOfSentencesWritten);
 		System.out.println("# texts written: " + numberOfTextsWritten);
-		
+
 		return numberOfWordsWritten;
 	}
-	
+
 	private static String[] getDefaultValues(MainCorpus mainCorpus, String property, int[] positions) throws UnexpectedAnswerException, IOException, CqiServerError, CqiClientException {
-		
-		String[] values = CQPSearchEngine.getCqiClient().cpos2Str(mainCorpus.getProperty(property).getQualifiedName(), positions);
-		for (int iupos = 0; iupos < values.length; iupos++) { // recode the || CQP multiple values to ud multiple values
-			if (values[iupos].length() > 2 && values[iupos].startsWith("|") && values[iupos].endsWith("|")) {
-				values[iupos] = values[iupos].substring(1, values[iupos].length() - 1);
+
+		if (mainCorpus.getProperty(property) != null) {
+			String[] emptyvalues = new String[positions.length];
+			for (int i = 0 ; i < emptyvalues.length ; i++) {
+				emptyvalues[i] = "_";
 			}
+			return emptyvalues;
+		} else {
+			String[] values = CQPSearchEngine.getCqiClient().cpos2Str(mainCorpus.getProperty(property).getQualifiedName(), positions);
+			for (int iupos = 0; iupos < values.length; iupos++) { // recode the || CQP multiple values to ud multiple values
+				if (values[iupos].length() > 2 && values[iupos].startsWith("|") && values[iupos].endsWith("|")) {
+					values[iupos] = values[iupos].substring(1, values[iupos].length() - 1);
+				}
+			}
+
+			return values;
 		}
-		
-		return values;
 	}
-	
+
 	private static HashMap<Integer, String> getNonUNDEFPositionsAndValues(MainCorpus mainCorpus, String property) throws UnexpectedAnswerException, IOException, CqiServerError, CqiClientException {
-		
+
 		HashMap<Integer, String> sentidStartPositions = new HashMap<>();
 		int[] ids = CQPSearchEngine.getCqiClient().regex2Id(mainCorpus.getProperty(property).getQualifiedName(), "(?!__UNDEF__).+");
 		String[] strs = CQPSearchEngine.getCqiClient().id2Str(mainCorpus.getProperty(property).getQualifiedName(), ids);
@@ -616,12 +618,12 @@
 				sentidStartPositions.put(p, strs[iId]);
 			}
 		}
-		
+
 		return sentidStartPositions;
 	}
-	
+
 	private static void fixUNDEFValues(String[] values) {
-		
+
 		for (int i = 0; i < values.length; i++) {
 			if (values[i].equals("__UNDEF__") || values[i].equals("") || values[i].equals("|_|")) {
 				values[i] = "_";
Index: TXM/trunk/bundles/org.txm.conllu.rcp/src/org/txm/conllu/rcp/commands/ImportCoNLLUAnnotationsFromDirectory.java
===================================================================
--- TXM/trunk/bundles/org.txm.conllu.rcp/src/org/txm/conllu/rcp/commands/ImportCoNLLUAnnotationsFromDirectory.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.conllu.rcp/src/org/txm/conllu/rcp/commands/ImportCoNLLUAnnotationsFromDirectory.java	(revision 3731)
@@ -189,6 +189,8 @@
 			return 0;
 		}
 		
+		mainCorpus.getProject().appendToHistory("CoNLL-U annotations imported from "+conlluDirectory+" : "+nTextProcessed+" texts and "+nWordsInserted+" words processed.");
+		
 		Log.info("XML-TXM source files updated. Updating indexes...");
 		
 		UDPreferences.getInstance().setProjectPreferenceValue(mainCorpus.getProject(), UDPreferences.UDPREFIX, propertiesPrefix);
@@ -226,6 +228,8 @@
 			return 0;
 		}
 		
+		mainCorpus.getProject().appendToHistory("CoNLL-U annotations imported from "+conlluFile+" texts and "+nWordsInserted+" words processed.");
+		
 		Log.info("XML-TXM source files updated. Updating indexes...");
 		
 		UDPreferences.getInstance().setProjectPreferenceValue(mainCorpus.getProject(), UDPreferences.UDPREFIX, propertiesPrefix);
Index: TXM/trunk/bundles/org.txm.annotation.kr.rcp/src/org/txm/annotation/kr/rcp/commands/ImportTable.java
===================================================================
--- TXM/trunk/bundles/org.txm.annotation.kr.rcp/src/org/txm/annotation/kr/rcp/commands/ImportTable.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.annotation.kr.rcp/src/org/txm/annotation/kr/rcp/commands/ImportTable.java	(revision 3731)
@@ -130,6 +130,7 @@
 					}
 					monitor.worked(30);
 					
+					corpus.getProject().appendToHistory("CQP Annotations imported from "+annotationsFile);
 					Log.info("Done.");
 					
 				} catch(Exception e) {
Index: TXM/trunk/bundles/org.txm.properties.rcp/src/org/txm/properties/rcp/editors/PropertiesGeneralTab.java
===================================================================
--- TXM/trunk/bundles/org.txm.properties.rcp/src/org/txm/properties/rcp/editors/PropertiesGeneralTab.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.properties.rcp/src/org/txm/properties/rcp/editors/PropertiesGeneralTab.java	(revision 3731)
@@ -1,5 +1,6 @@
 package org.txm.properties.rcp.editors;
 
+import java.io.IOException;
 import java.util.Date;
 
 import org.eclipse.jface.viewers.DecoratingLabelProvider;
@@ -19,28 +20,32 @@
 import org.eclipse.swt.widgets.TabFolder;
 import org.eclipse.swt.widgets.Text;
 import org.txm.core.results.TXMResult;
+import org.txm.objects.CorpusBuild;
+import org.txm.objects.Project;
 import org.txm.properties.rcp.Messages;
 import org.txm.properties.rcp.messages.PropertiesUIMessages;
 import org.txm.rcp.IImageKeys;
 import org.txm.rcp.editors.TXMBrowserEditor;
 import org.txm.rcp.views.corpora.CorporaView;
+import org.txm.utils.logger.Log;
 
 public class PropertiesGeneralTab extends PropertiesTab {
-	
+
 	private Text nameField;
 	private Browser browser;
-	
+	private Text historyText;
+
 	public PropertiesGeneralTab(TabFolder folder, PropertiesPagedEditor editor2) {
 		super(folder, editor2);
 		tab.setText(Messages.PropertiesGeneralTab_0);
-		
+
 		parent.getLayout().numColumns = 3;
 		parent.getLayout().makeColumnsEqualWidth = false;
 		parent.getLayout().verticalSpacing = 10;
 		parent.getLayout().horizontalSpacing = 10;
 		parent.getLayout().marginTop = 10;
 		parent.getLayout().marginLeft = 10;
-		
+
 		Label image = new Label(parent, SWT.NONE);
 		// image.setImage(IImageKeys.getImage(""));
 		IBaseLabelProvider lp = CorporaView.getInstance().getTreeViewer().getLabelProvider();
@@ -54,30 +59,30 @@
 			}
 		}
 		image.setLayoutData(new GridData(GridData.BEGINNING, GridData.BEGINNING, false, true, 1, 8));
-		
+
 		new Label(parent, SWT.NONE);
 		Button clipButton = new Button(parent, SWT.PUSH);
 		clipButton.setLayoutData(new GridData(GridData.END, GridData.END, false, false));
 		clipButton.setText(Messages.PropertiesGeneralTab_11);
 		clipButton.addSelectionListener(new SelectionListener() {
-			
+
 			@Override
 			public void widgetSelected(SelectionEvent e) {
 				toClipboard();
 			}
-			
+
 			@Override
 			public void widgetDefaultSelected(SelectionEvent e) {}
 		});
-		
+
 		Label l = new Label(parent, SWT.NONE);
 		l.setText(Messages.PropertiesGeneralTab_1);
-		
+
 		nameField = new Text(parent, SWT.BORDER);
 		nameField.setLayoutData(new GridData(GridData.BEGINNING, GridData.BEGINNING, true, false));
 		nameField.setText(editor.getResult().getParent().getUserName());
 		nameField.addKeyListener(new KeyListener() {
-			
+
 			@Override
 			public void keyReleased(KeyEvent e) {
 				if (e.keyCode == SWT.CR || e.keyCode == SWT.KEYPAD_CR && nameField.getText().length() > 0 && !nameField.getText().equals(editor.getResult().getParent().getUserName())) {
@@ -86,25 +91,27 @@
 					CorporaView.refreshObject(editor.getResult().getParent());
 				}
 			}
-			
+
 			@Override
 			public void keyPressed(KeyEvent e) {}
 		});
-		new Label(parent, SWT.NONE).setText(Messages.PropertiesGeneralTab_3);
-		l = new Label(parent, SWT.NONE);
-		l.setLayoutData(new GridData(GridData.BEGINNING, GridData.BEGINNING, true, false));
-		l.setText(editor.getResult().getParent().getResultType());
 		
-		// new Label(parent, SWT.NONE).setText("Size");
-		// l = new Label(parent, SWT.NONE);
-		// l.setLayoutData(new GridData(GridData.BEGINNING, GridData.BEGINNING, true, false));
-		// l.setText(""+editor.getResult().getParent().getChildren().size());
-		
-		new Label(parent, SWT.NONE).setText(Messages.PropertiesGeneralTab_4);
-		l = new Label(parent, SWT.NONE);
-		l.setLayoutData(new GridData(GridData.BEGINNING, GridData.BEGINNING, true, false));
-		l.setText("" + editor.getResult().getParent().getFullPathSimpleName(false));// .getParent().getParent().getUserName()); //$NON-NLS-1$
-		
+//		new Label(parent, SWT.NONE).setText(Messages.PropertiesGeneralTab_3);
+//		
+//		l = new Label(parent, SWT.NONE);
+//		l.setLayoutData(new GridData(GridData.BEGINNING, GridData.BEGINNING, true, false));
+//		l.setText(editor.getResult().getParent().getResultType());
+//
+//		// new Label(parent, SWT.NONE).setText("Size");
+//		// l = new Label(parent, SWT.NONE);
+//		// l.setLayoutData(new GridData(GridData.BEGINNING, GridData.BEGINNING, true, false));
+//		// l.setText(""+editor.getResult().getParent().getChildren().size());
+//
+//		new Label(parent, SWT.NONE).setText(Messages.PropertiesGeneralTab_4);
+//		l = new Label(parent, SWT.NONE);
+//		l.setLayoutData(new GridData(GridData.BEGINNING, GridData.BEGINNING, true, false));
+//		l.setText("" + editor.getResult().getParent().getFullPathSimpleName(false));// .getParent().getParent().getUserName()); //$NON-NLS-1$
+
 		new Label(parent, SWT.NONE).setText(Messages.PropertiesGeneralTab_6);
 		l = new Label(parent, SWT.NONE);
 		l.setLayoutData(new GridData(GridData.BEGINNING, GridData.BEGINNING, true, false));
@@ -112,7 +119,7 @@
 		if (d != null) {
 			l.setText("" + TXMResult.PRETTY_LOCALIZED_TIME_FORMAT.format(d)); //$NON-NLS-1$
 		}
-		
+
 		new Label(parent, SWT.NONE).setText(Messages.PropertiesGeneralTab_8);
 		l = new Label(parent, SWT.NONE);
 		l.setLayoutData(new GridData(GridData.BEGINNING, GridData.BEGINNING, true, false));
@@ -123,7 +130,7 @@
 		else {
 			l.setText(Messages.PropertiesGeneralTab_10);
 		}
-		
+
 		// l = new Label(parent, SWT.SEPARATOR_FILL);
 		// l.setLayoutData(new GridData(GridData.FILL, GridData.FILL, true, false, 2, 1));
 		//
@@ -146,20 +153,20 @@
 		// @Override
 		// public void keyPressed(KeyEvent e) {}
 		// });
-		
+
 		l = new Label(parent, SWT.NONE);
 		l.setLayoutData(new GridData(GridData.BEGINNING, GridData.BEGINNING, false, false));
 		l.setText(PropertiesUIMessages.Description);
-		
+
 		browser = new Browser(parent, SWT.H_SCROLL | SWT.V_SCROLL);
 		browser.setLayoutData(new GridData(GridData.FILL, GridData.FILL, true, true, 1, 1));
 		browser.setText(editor.getResult().getProject().getDescription());
-		
+
 		browser.addMouseWheelListener(new MouseWheelListener() {
-			
+
 			@Override
 			public void mouseScrolled(MouseEvent e) {
-				
+
 				if ((e.stateMask & SWT.CTRL) == SWT.CTRL) {
 					if (e.count > 0) {
 						TXMBrowserEditor.zoomIn(browser);
@@ -169,8 +176,42 @@
 				}
 			}
 		});
+
+		if (editor.getResult().getParent() instanceof CorpusBuild || editor.getResult().getParent() instanceof Project) {
+			l = new Label(parent, SWT.NONE);
+			l.setLayoutData(new GridData(GridData.BEGINNING, GridData.BEGINNING, false, false));
+			l.setText("History");
+
+			historyText = new Text(parent, SWT.H_SCROLL | SWT.V_SCROLL);
+			historyText.setLayoutData(new GridData(GridData.FILL, GridData.FILL, true, true, 1, 1));
+			try {
+				historyText.setText(editor.getResult().getProject().getHistory());
+			} catch (IOException e1) {
+				// TODO Auto-generated catch block
+				e1.printStackTrace();
+			}
+
+			
+			l = new Label(parent, SWT.NONE);
+			l.setLayoutData(new GridData(GridData.BEGINNING, GridData.BEGINNING, false, false));
+			
+			Button saveHistoryButton = new Button(parent, SWT.PUSH);
+			saveHistoryButton.setLayoutData(new GridData(GridData.BEGINNING, GridData.BEGINNING, false, false));
+			saveHistoryButton.setText("Save the history content");
+			saveHistoryButton.addSelectionListener(new SelectionListener() {
+
+				@Override
+				public void widgetSelected(SelectionEvent e) {
+					editor.getResult().getProject().writeHistory(historyText.getText());
+					Log.info("History saved.");
+				}
+
+				@Override
+				public void widgetDefaultSelected(SelectionEvent e) { }
+			});
+		}
 	}
-	
+
 	public void toClipboard() {
 		StringBuffer buffer = new StringBuffer();
 		buffer.append(Messages.PropertiesGeneralTab_12 + editor.getResult().getParent().getUserName());
@@ -185,7 +226,7 @@
 		if (d != null) {
 			buffer.append(Messages.PropertiesGeneralTab_18 + TXMResult.PRETTY_LOCALIZED_TIME_FORMAT.format(d));
 		}
-		
+
 		buffer.append("\n"); //$NON-NLS-1$
 		d = editor.getResult().getParent().getCreationDate();
 		if (d != null) {
@@ -194,17 +235,25 @@
 		else {
 			buffer.append(Messages.PropertiesGeneralTab_21);
 		}
-		
+
 		org.txm.rcp.utils.IOClipboard.write(buffer.toString());
 	}
-	
+
 	@Override
 	public void updateResultFromEditor(boolean update) {
 		// TODO Auto-generated method stub
 	}
-	
+
 	@Override
 	public void updateEditorFromResult() {
-		// TODO Auto-generated method stub
+
+		try {
+			browser.setText(editor.getResult().getProject().getDescription());
+			historyText.setText(editor.getResult().getProject().getHistory());
+		} catch (IOException e1) {
+			// TODO Auto-generated catch block
+			e1.printStackTrace();
+		}
+		
 	}
 }
Index: TXM/trunk/bundles/org.txm.searchengine.core/src/org/txm/searchengine/core/Query.java
===================================================================
--- TXM/trunk/bundles/org.txm.searchengine.core/src/org/txm/searchengine/core/Query.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.searchengine.core/src/org/txm/searchengine/core/Query.java	(revision 3731)
@@ -66,6 +66,26 @@
 		return str.toString();
 	}
 	
+	/**
+	 * Converts the specified Query to a string.
+	 * contains the query string and the query engine
+	 * 
+	 * @param q the query to serialize
+	 * @return
+	 */
+	public static String queryToString(IQuery q) {
+
+		return q.getQueryString() + TXMPreferences.LIST_SEPARATOR + q.getSearchEngine().getName();
+	}
+	
+	@Override
+    public int hashCode() {
+		if (queryString != null && engine != null) {
+			return queryString.hashCode() + engine.getName().hashCode();
+		}
+		return super.hashCode();
+    }
+	
 	public boolean canBeMultiLine() {
 		return false;
 	}
@@ -121,7 +141,9 @@
 		}
 		
 		SearchEngine e = SearchEnginesManager.getSearchEngine(eName);
-		return new Query(split[0], e);
+		Query q = e.newQuery();
+		q.setQuery(split[0]);
+		return q;
 	}
 	
 	
Index: TXM/trunk/bundles/org.txm.searchengine.core/src/org/txm/searchengine/core/QueryHistory.java
===================================================================
--- TXM/trunk/bundles/org.txm.searchengine.core/src/org/txm/searchengine/core/QueryHistory.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.searchengine.core/src/org/txm/searchengine/core/QueryHistory.java	(revision 3731)
@@ -2,6 +2,7 @@
 
 import java.io.BufferedReader;
 import java.io.File;
+import java.io.IOException;
 import java.io.PrintWriter;
 import java.util.ArrayList;
 import java.util.LinkedHashSet;
@@ -14,13 +15,18 @@
 import org.txm.utils.io.IOUtils;
 
 public class QueryHistory extends TXMResult {
-	
+
 	LinkedHashSet<IQuery> queries = new LinkedHashSet<IQuery>(); // first is the older and last is the newer
-	
+	boolean modified = false;
+
 	public QueryHistory(String parametersNodePath, TXMResult parent) {
 		super(parametersNodePath, parent);
 	}
-	
+
+	public QueryHistory(String parametersNodePath) {
+		super(parametersNodePath, null);
+	}
+
 	public QueryHistory(Project corpus) {
 		super(null, corpus);
 	}
@@ -30,7 +36,7 @@
 
 		return true;
 	}
-	
+
 	@Override
 	public boolean isVisible() {
 
@@ -69,7 +75,7 @@
 
 	@Override
 	public void clean() {
-		
+
 	}
 
 	@Override
@@ -77,35 +83,29 @@
 
 		return true;
 	}
-	
+
 	public Project getParent() {
 		return (Project) super.getParent();
 	}
 
 	@Override
+	public void onProjectClose() {
+		saveQueriesToFile();
+	}
+
+	@Override
+	public void onWorkspaceClose() {
+		saveQueriesToFile();
+	}
+
+	@Override
 	protected boolean _compute(TXMProgressMonitor monitor) throws Exception {
 		queries.clear();
-		
-		File logFile = new File(this.getParent().getProjectDirectory(), "queries.txt");
-		int MAX = TBXPreferences.getInstance().getInt(TBXPreferences.QUERY_HISTORY_SIZE);
-		
-		BufferedReader reader = IOUtils.getReader(logFile);
-		String line = reader.readLine();
-		while (line != null) {
-			line = line.trim();
-			if (line.length() > 0 && !line.startsWith("#")) {
-				IQuery q = Query.stringToQuery(line);
-				queries.add(q);
-			}
-			
-			if (queries.size() > MAX) break;
-			line = reader.readLine();
-		}
-		reader.close();
-		
+
+		loadQueriesFromFile();
 		return true;
 	}
-	
+
 	@SuppressWarnings("unchecked")
 	public <Q extends IQuery> ArrayList<Q> getQueries(Class<Q> clazz) {
 		ArrayList<Q> ret = new ArrayList<Q>();
@@ -115,35 +115,80 @@
 			}
 		}
 		return ret;
-		
+
 	}
-	
+
+
+	public boolean saveQueriesToFile() {
+
+		if (modified) {
+			File logFile = new File(this.getParent().getProjectDirectory(), "QUERIES");
+			try {
+				return _toTxt(logFile, "UTF-8", "", "");
+			} catch (Exception e) {
+				// TODO Auto-generated catch block
+				e.printStackTrace();
+			}
+			return false;
+		}
+		return true;
+	}
+
+	public void loadQueriesFromFile() throws IOException {
+
+		File logFile = new File(this.getParent().getProjectDirectory(), "QUERIES");
+		if (logFile.exists() && logFile.canRead()) {
+			int MAX = TBXPreferences.getInstance().getInt(TBXPreferences.QUERY_HISTORY_SIZE);
+
+			BufferedReader reader = IOUtils.getReader(logFile);
+			String line = reader.readLine();
+			while (line != null) {
+				line = line.trim();
+				if (line.length() > 0 && !line.startsWith("#")) {
+					IQuery q = Query.stringToQuery(line);
+					queries.add(q);
+				}
+
+				if (queries.size() > MAX) break;
+				line = reader.readLine();
+			}
+			reader.close();
+			modified = false;
+		}
+	}
+
 	public void addQuery(IQuery query) {
-		
+
 		int MAX = TBXPreferences.getInstance().getInt(TBXPreferences.QUERY_HISTORY_SIZE);
 		reduceSize(MAX - 1); // ensure history size limit
+		queries.remove(query);
 		queries.add(query);
+		modified = true;
 	}
-	
+
 	public void reduceSize(int MAX) {
-		
-		while (queries.size() > MAX && queries.size() > 0) {
-			for (IQuery q : queries) {
+		int diff = queries.size() - MAX;
+		if (diff > 0) { // there are more queries than MAX
+			for (IQuery q : queries) { // remove until diff == 0
 				queries.remove(q);
-				break;  // remove 1 query
+				diff--;
+				if (diff <= 0) {
+					break;
+				}
 			}
+			modified = true;
 		}
 	}
 
 	@Override
 	protected boolean _toTxt(File outfile, String encoding, String colseparator, String txtseparator) throws Exception {
-		
+
 		PrintWriter writer = IOUtils.getWriter(outfile, encoding);
 		for (IQuery q : queries) {
-			writer.println(q);
+			writer.println(Query.queryToString(q));
 		}
 		writer.close();
-		
+
 		return true;
 	}
 
Index: TXM/trunk/bundles/org.txm.conllu.core/src/org/txm/conllu/core/function/ImportCoNLLUAnnotations.java
===================================================================
--- TXM/trunk/bundles/org.txm.conllu.core/src/org/txm/conllu/core/function/ImportCoNLLUAnnotations.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.conllu.core/src/org/txm/conllu/core/function/ImportCoNLLUAnnotations.java	(revision 3731)
@@ -38,6 +38,10 @@
 			udPropertiesToImport.add("dep-"+p);
 		}
 		
+		if (!udPropertiesToImport.contains("id")) {
+			Log.warning("The UD based commands need at least the 'id' property to properly work.");
+		}
+		
 		Log.info("** processing text: " + textId);
 		Text text = mainCorpus.getProject().getText(textId);
 		if (text == null) {
Index: TXM/trunk/bundles/org.txm.conllu.core/src/org/txm/conllu/core/function/UDTreeSearch.java
===================================================================
--- TXM/trunk/bundles/org.txm.conllu.core/src/org/txm/conllu/core/function/UDTreeSearch.java	(revision 3730)
+++ TXM/trunk/bundles/org.txm.conllu.core/src/org/txm/conllu/core/function/UDTreeSearch.java	(revision 3731)
@@ -126,8 +126,17 @@
 //				NTvalues = corpus.getProperty(NT).cpos2Str(positions);
 //			}
 			HashMap<String, String[]> values = new HashMap<>();
+			String[] emptyvalues = new String[positions.length];
+			for (int i = 0 ; i < emptyvalues.length ; i++) {
+				emptyvalues[i] = "_";
+			}
 			for (String p : ImportCoNLLUAnnotations.UD_PROPERTY_NAMES) {
-				values.put(prefix+p, corpus.getProperty(prefix+p).cpos2Str(positions));
+				
+				if (corpus.getProperty(prefix+p) != null) {
+					values.put(prefix+p, corpus.getProperty(prefix+p).cpos2Str(positions));
+				} else { // in case the CQP property does not exists, use empty values
+					values.put(prefix+p, emptyvalues);
+				}
 			}
 			
 			ArrayList<String> conll = new ArrayList<String>();
@@ -375,15 +384,22 @@
 	
 	public static boolean hasUDProperties(CQPCorpus corpus, String prefix) {
 		
-		for (String prop : ImportCoNLLUAnnotations.UD_PROPERTY_NAMES) {
-			try {
-				if (corpus.getProperty(prefix+prop) == null) return false;
-			}
-			catch (CqiClientException e) {
-				return false;
-			}
+//		for (String prop : ImportCoNLLUAnnotations.UD_PROPERTY_NAMES) {
+//			try {
+//				if (corpus.getProperty(prefix+prop) == null) return false;
+//			}
+//			catch (CqiClientException e) {
+//				return false;
+//			}
+//		}
+//		return true;
+		
+		try {
+			return corpus.getProperty(prefix+"id") != null;
 		}
-		return true;
+		catch (CqiClientException e) {
+			return false;
+		}
 	}
 
 	@Override
Index: TXM/trunk/bundles/org.txm.groovy.core/src/groovy/org/txm/macro/annotation/ImportWordPropertiesFromTableMacro.groovy
===================================================================
--- TXM/trunk/bundles/org.txm.groovy.core/src/groovy/org/txm/macro/annotation/ImportWordPropertiesFromTableMacro.groovy	(revision 3730)
+++ TXM/trunk/bundles/org.txm.groovy.core/src/groovy/org/txm/macro/annotation/ImportWordPropertiesFromTableMacro.groovy	(revision 3731)
@@ -41,6 +41,9 @@
 )
 
 if (ret) {
+	
+	corpusViewSelection.getProject().appendToHistory("$properties imported from the $csvFile file")
+	
 	org.txm.rcp.commands.workspace.UpdateCorpus.update(corpusViewSelection, update_edition)
 	return true
 } else {
