diff --git a/aqt/importing.py b/aqt/importing.py index 2ada664af..27787ec4c 100644 --- a/aqt/importing.py +++ b/aqt/importing.py @@ -112,6 +112,11 @@ you can enter it here. Use \\t to represent tab."""), self, help="importing") or "\t" str = str.replace("\\t", "\t") str = str.encode("ascii") + if len(str) > 1: + showWarning(_( + "Multi-character separators are not supported. " + "Please enter one character only.")) + return self.hideMapping() def updateDelim(): self.importer.delimiter = str @@ -140,7 +145,7 @@ you can enter it here. Use \\t to represent tab."""), d = repr(d) txt = _("Fields separated by: %s") % d self.frm.autoDetect.setText(txt) - + def accept(self): self.importer.mapping = self.mapping if not self.importer.mappingOk():