SMILES don't display, MOLs are fine

User 248fb9fe9c

22-07-2004 15:43:18

Hi,


I'm trying to do a very simple example:





<script language="JavaScript1.1">


<!--


mview_begin(".", 300, 300);


mview_param("rows", 1);


mview_param("cols", 2);


mview_param("cell0", "|caffeine.mol");


mview_param("cell1", "|c12c(c(cc(c1O)C(Nc1cc(ccc1)N)=O)Cl)cccc2");


mview_end();


-->


</script>





The caffeine molecule is displayed fine. The SMILES one isn't displayed at all. Why is that?





The same thing happens if I just do the SMILES one by itself using the "mol" params instead of "cell1" and outside a table, e.g.


<script language="JavaScript1.1">


<!--


mview_begin(".", 300, 300);


mview_param("mol", "|c12c(c(cc(c1O)C(Nc1cc(ccc1)N)=O)Cl)cccc2");


mview_end();


-->


</script>





This is on Internet Explorer 6 with all the latest updates, Windows 2000, JDK 1.4.2_04 installed. It's the same behavior whether I use the <applet> tag or the marvin.js functions.





(And yes, the marvin.js file, marvin.jar, jmarvin.jar, caffeine.mol are in the same directory as the test .html file, so the codebase of "." is correct).





Any ideas are appreciated. Thanks in advance ;)





Yoav Shapira

ChemAxon fb166edcbd

23-07-2004 17:38:06

I tried to reproduce this and the result is:





1, your first example worked OK,


both molecules were displayed on both


Netscape/Linux and IE 6/Windows.





2, in the second example where you use the "mol" parameter,


you should not put a separator sign in front of the SMILES


and then it works (otherwise a file format not recognised message


is displayed). The correct code is:





<script LANGUAGE="JavaScript1.1" SRC="./marvin.js"></script>


<script language="JavaScript1.1">


<!--


mview_begin(".", 200, 200);


mview_param("mol", "c12c(c(cc(c1O)C(Nc1cc(ccc1)N)=O)Cl)cccc2");


mview_end();


-->


</script>





Nora

User 248fb9fe9c

26-07-2004 12:59:22

I will try it out -- thanks.