Search the web
Sign In
New User? Sign Up
CType · Content-Type
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Hear how Yahoo! Groups has changed the lives of others. Take me there.

Best of Y! Groups

   Check them out and nominate your group.
Having problems with message search? Fill out this form to ensure your group is one of the first to be migrated to the new message search system.

Messages

  Messages Help
Advanced
standalone webservice client application   Message List  
Reply | Forward Message #5 of 5 | Next >
hi guys,

Im new to this group and hope u dont mind my asking...I created a web
service client using WSDK 5.1 (websphere application client). When i
run it in websphere it works fine.. it
uses "java:env/comp/service/OasysTest" as the jndi lookup... however,
it is supposed to be standalone swing application so I need to run it
from command line. from what i gathered this kind of lookup wont work
in standalone app..so i made some revisions.. however, i cant seem to
get it right since it wont run anymore..i keep getting th
error "javax.naming.NameNotFoundException:
service/OasysTestService" .. this is my first time to develop a
webservice..is someone kind enuff to tell me what im doing wrong..
pls see the code fragment below:

public String extractOasysFile(int userid, String branchId){
String oasysMsg = "";
InitialContext ic = null;
OasysTestService factory = null;

Hashtable env = new Hashtable();
env.put
(Context.INITIAL_CONTEXT_FACTORY, "com.ibm.websphere.naming.WsnInitial
ContextFactory");

env.put(Context.PROVIDER_URL, "iiop://202.138.137.71:2809");
try{
ic = new InitialContext(env);
factory = (OasysTestService)ic.lookup("service/OasysTestService");

}catch (NamingException e){
e.printStackTrace();
}

try{
OasysTest ot = factory.getOasysTest();
try{
oasysMsg = ot.extractOasysFile(userid,branchId);
}catch(RemoteException e){
e.printStackTrace();
}
}catch(ServiceException se){
se.printStackTrace();
}

return oasysMsg;

}






Mon Jun 21, 2004 5:41 am

freaksamadhi
Offline Offline
Send Email Send Email

Forward
Message #5 of 5 | Next >
Expand Messages Author Sort by Date

hi guys, Im new to this group and hope u dont mind my asking...I created a web service client using WSDK 5.1 (websphere application client). When i run it in...
jett
freaksamadhi
Offline Send Email
Jun 22, 2004
2:13 pm
< Prev Topic  |  Next Topic >
Advanced

Copyright © 2009 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines - Help