Angel is right -- you need quotes there:

viewer.script("pmesh me \""+str + "\"")

all double quotes for Java and Jmol.



sushil ronghe wrote:

>
> Thanks bob it is working great!
>
> one more thing i am giving the command  :: pmesh me "filename.txt"
> as  viewer.script("pmesh me"+str) //str is the absolute path of the file
>  in org.openscience.jmol.app.jmol.java
> and got the error "pmesh me >> / << u0 / sushil / myjmol / xmlpath . txt"
>
> then i kept the file in same director and now code looks like
> String str = new String("XMLPATH.txt");
>             viewer.script("pmesh me"+str);
>
> again i got the error
> pmesh mexmlpath >> . << txt
>
> I understand that . and / charecters are not expected in the argument.
> so what could be the command in viewer.script to read the pmesh file.
>
>
>  
>
>     > Thanks for adding  more example on pmesh tutorial.
>     > I have generated a txt file for my mesh.
>     >
>     > while running the command pmesh myMesh.txt
>     > i am not getting anything(atleast a error message)
>     > the script editor just saying
>     > script completed!
>     >
>     > I am sure the file i have created is according to format.
>     > LINE 1: number of points
>     > LINE 2-n: N number of coordinates
>     > LINE 3: Number of planes
>     > LINE 4-m:m set of coordinate index
>
>     it's that LINE 4 that is causing you the problems. For example:
>
>     >4
>     >130
>     >142
>     >143
>     >131
>     >
>     >
>     >
>     >
>     should read
>
>     5
>     130
>     142
>     143
>     131
>     130
>
>
> -- 
> ********************************
> sushil ronghe
> *********************************
>
>------------------------------------------------------------------------
>
>-------------------------------------------------------------------------
>This SF.net email is sponsored by: Microsoft
>Defy all challenges. Microsoft(R) Visual Studio 2005.
>http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
>
>------------------------------------------------------------------------
>
>_______________________________________________
>Jmol-users mailing list
>[email protected]
>https://lists.sourceforge.net/lists/listinfo/jmol-users
>  
>


-- 
Robert M. Hanson
Professor of Chemistry
St. Olaf College
Northfield, MN
http://www.stolaf.edu/people/hansonr


If nature does not answer first what we want,
it is better to take what answer we get. 

-- Josiah Willard Gibbs, Lecture XXX, Monday, February 5, 1900



-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Jmol-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jmol-users

Reply via email to