We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpSyntax Questions › Importing classes in a program
Page Index Toggle Pages: 1
Importing classes in a program (Read 240 times)
Importing classes in a program
Oct 24th, 2008, 5:36pm
 
Hi,
I have defined a class and I want to costruct an object of that class in another program.
What I have to do?

How can I import that class?
Have I to use the package keyword and saving the class with
the extension .java? Or the extension has to be .pde?

I do not know the right sintax...please help.


Thanks in advance
Re: Importing classes in a program
Reply #1 - Oct 24th, 2008, 8:34pm
 
just copy and paste your class into the new sketch.
or save it into a regular .pde file and copy it into the new sketch directory.
that's it.
Re: Importing classes in a program
Reply #2 - Oct 25th, 2008, 4:39am
 
Really really thanks.
Page Index Toggle Pages: 1