User 8170b160d9
11-08-2010 22:56:41
Hi, Sir,
I use marvin sketch in a web to let user input structure, and then put into database, when I export these structures to sdf, and import to isis base. structures can not be displayed normally in isis base. I try to import sdf drawed by isis base using marvin sketch, then export using same code to a sdf file. again I import the sdf to isis base. these structures can be displayed normally.
my export code snippet:
foreach (var item in inventorys)
{
Molecule mol = new Molecule();
MolImporter.importMol(item.Structure, mol);
mol.setProperty("Name", item.EnglishName);
mol.setProperty("CAS", item.CAS);
if (ExportQtyCheckBox.Checked)
mol.setProperty("Quantity", string.Format("{0} {1}", item.Quantity, item.UnitMeasureCode));
sdfExporter.write(mol);
}
sdfExporter.close();