Am Thursday 14 September 2006 12:28 schrieb Kristina Grabowski:
> Hi all, I used JChemPaintEditorPanel as following, but I got error
> messages. I don?t know what?s wrong.
> It?s said in JChemPaintEditorPanel.class that class JChemPaintPanel
> cannot be found, although I can find that class in my jar file.
> I?m using JChemPaint-2.2.1.jar and CDK20060714. Any Ideas?

I am not quite sure what you are using, but I think you mix up things: The 
JCP2.2.1.jar should contain everything needed, including cdk. If you want to 
use the cdk disttribution, there should be several jars called cdk-x.jar, 
including cdk-jchempaint.jar. You should not combine the two types of jars, 
since they might be from different dates and therefore incompatible.
Stefan

>
> Thank you, Tina
>
> import java.awt.BorderLayout;
> import java.awt.Dimension;
> import java.awt.event.MouseAdapter;
> import java.awt.event.MouseEvent;
> import java.io.File;
> import java.util.Calendar;
> import javax.swing.JButton;
> import javax.swing.JFrame;
> import javax.swing.JPanel;
> import javax.swing.LookAndFeel;
> import org.openscience.cdk.Molecule;
> import org.openscience.cdk.applications.jchempaint.JCPPropertyHandler;
> import org.openscience.cdk.applications.jchempaint.JChemPaintEditorPanel;
> import org.openscience.cdk.applications.jchempaint.JChemPaintModel;
> import org.openscience.cdk.applications.jchempaint.JChemPaintPanel;
>
> public class JChemPaintDialog extends javax.swing.JDialog {
>
>    public static void main(String[] args) {
>        JFrame frame = new JFrame();
>        JChemPaintDialog inst = new JChemPaintDialog(frame);
>        inst.setVisible(true);
>    }
>      public JChemPaintDialog(JFrame frame) {
>        super(frame,"Please draw a molecule",true);
>        initGUI();
>        }
>
>      private void initGUI() {
>        try {
>            {
>                BorderLayout thisLayout = new BorderLayout();
>                this.getContentPane().setLayout(thisLayout);
>                this.setPreferredSize(new java.awt.Dimension(600,
> 400));
>                this.setLocation(new java.awt.Point(100, 100));
>            }
>            {
>                jChemPanel = new JChemPaintEditorPanel();
>                jChemPanel.setEmbedded();
>                JChemPaintModel model = new JChemPaintModel();
>                .......

-- 
Stefan Kuhn B. Sc. M. A.
Cologne University BioInformatics Center (http://www.cubic.uni-koeln.de)
Zülpicher Str. 47, 50674 Cologne
Tel: +49(0)221-470-7428   Fax: +49 (0) 221-470-7786
My public PGP key is available at http://pgp.mit.edu

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Cdk-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/cdk-user

Reply via email to