Author Message
MichaelDailous_deprecated
Joined: Nov 11, 2013
Messages: 171
Offline
When running an application through the built-in simulator, the method call to getInitParameter(..) always returns a null object. I've tested with the context-param "sage.startlanguage" as well as any additions added by any of my PDC's. Is there something I need to configure to allow this function to work?

Thank you,
Michael
MichaelDailous_deprecated
Joined: Nov 11, 2013
Messages: 171
Offline
Additional information:

I just deployed the application to a test server, and the same problem exists when running the application on a server. Any method call from within a Data servlet to "getinitParam("sage.startlange")" or "mySession.getServlet().getInitParameter("sage.startlanguage")" returns null. In the web.xml file, the value of "sage.startlanguage" is "english".

Michael
WilsonYu
Joined: Nov 6, 2013
Messages: 3950
Offline
Did you try it on a SCESession object:

getServlet().getServletContext().getInitParameter

Essentially SCESession.getParameter would do the same thing.

It gets the value from web.xml
MichaelDailous_deprecated
Joined: Nov 11, 2013
Messages: 171
Offline
Hi Wilson, both of those did the trick! Not sure why the getInitParameter(...) isn't working, but this works without issue.

Thank you! :)
Michael
Go to:   
Mobile view