Need to call a java file from as1.0

Need help with SmartFoxServer? You didn't find an answer in our documentation? Please, post your questions here!

Moderators: Lapo, Bax

sankarganesh86
Posts: 108
Joined: 06 Jan 2010, 09:50
Location: chennai
Contact:

Need to call a java file from as1.0

Postby sankarganesh86 » 22 Sep 2011, 10:30

hi,
Actually i need to call a normal java file from AS1.0 extension
so i done some changes in SFS server they are below

SFSpath/Server/conf/wrapper.conf
in the above file i add a line (wrapper.java.classpath.40=./javaExtensions/)

&

SFSpath/Server/start.bat
in the above file i add (./javaExtensions/) next to the ./sfsExtensions

and i create a normal java file name (one.java) and get class file (one.class)

in the sfsExtension i create (example.as)

var test = new Packages.one(); --> used to create a object
and i have another function inside the one.java
so i call .. test.getName(); & and i tested in a system it is working fine but

the same scenario i done in another system i got

Error in extension [example.as]: TypeError:[java package one] is not a function,
it is org.mozilla.javascript.nativejavapackage.

At the Server start up ...what is the problem ? what i need to do ?
User avatar
BigFIsh
Posts: 1698
Joined: 25 Feb 2008, 19:26
Location: New Zealand

Postby BigFIsh » 22 Sep 2011, 22:03

It's hard to tell what's going on from here. I would suggest double checking everything starting from a fresh installation of Java RE (if needed).
Smartfox's forum is my daily newspaper.

Return to “SmartFoxServer 1.x Discussions and Help”

Who is online

Users browsing this forum: No registered users and 24 guests