This content has been marked as final.
Show 1 reply
-
1. Re: no access to ServletContext
bstansberry Mar 26, 2004 3:51 PM (in response to lrae)Which init() method are you overriding?
init()
or init(ServletConfig config)
If it's the latter, be sure the first line in the method body is
super.init(config);
or else the ServletConfig object will not be stored by the servlet and you will get the errors you report.
Better yet, override the no-arguments init(), as the purpose of the no-arg version is to avoid having to call super.init(config).
Best,
Brian