molecule toBinFormat() returning empty byte[]

User 8604712a60

24-06-2011 19:32:46

I'm trying to get a byte array from a molecule object so that I can create an image to be displayed in an asp.net page.


I'm using data retrieved from the structure table. I'm able to create a molecule from the cd_structure blob or the cd_smiles data however when I try to create a byte array by the toBinFormat ("jpeg:h300,w300") method, the byte array returned is empty.


The toObject (as Image) method won't work as it returns a java based buffered image which isn't accepted by either the System.Drawing.Bitmap or Image constructors which then leads me back to needing a byte array for that conversion.


Do you have any examples I could look at?


Thanks,


Molly


 

ChemAxon bd13b5bd77

25-06-2011 07:14:54

Dear Molly,


 


please check this post:


https://www.chemaxon.com/forum/ftopic7393.html


 


Viktor

User 8604712a60

25-06-2011 15:01:58

Perfect, thanks.