-
FEATURED COMPONENTS
First time here? Check out the FAQ!
I want to set some variables in application.
in zscript, we can do like this:
------------
application.setAttribute("user",myuserbean);
------------
but zscript is not encouraged because it will slow the project a bit.
so I want to setAttribute in java files.
I've tryed: new WebApp().setAttribute();
but error said:"can't realize WebApp".it seems to be a static class.
so I tryed: WebApp().setAttribute();
error said:"setAttribute() is not a static method."
the How could I get the application Object?
thanks for supply any information.
Please try:
Sessions.getCurrent().getWebApp()
Cheers, Maik
Asked: 2008-12-29 09:25:53 +0800
Seen: 248 times
Last updated: Dec 30 '08