This content has been marked as final. Show 3 replies
If you have added the object instantiation to OnApplicationStart() to an already running application then it will not exist in the application scope until the application is restarted. You can call OnApplicationStart() programatically from within your Application.cfc or you can just restart coldfusion.
> However now I get the error
> Element USER is undefined in a Java object of type class [Ljava.lang.String;
> referenced as
Can you post the code that creates application.user?
Thanx Stressed. You hit me with a "DOH!" moment. lol
I have a "reinit" in my application.cfc file which does exactly what you said about calling the onApplicationStart(). BUT I decided to check it again and make sure it was okay and what to my amazement should I find? Some evil code demon had put it INSIDE the onApplicationStart function.
So, moving it outside of the function where it should be, it now works fine.
*banging head against wall*