Find your people. Pick a challenge. Ship something real. The CreatorCon Hackathon is coming to the Community Pavilion for one epic night. Every skill level, every role welcome. Join us on May 5th and learn more here.

Script Include

edmilsonsil
Tera Contributor

I'm having a problem where I can't call a hidden include script within a scheduled job script.

1 REPLY 1

Matthew_13
Mega Sage

Hi my Friend

 Most likely your scheduled job is running in a different scope than the Script Includes?, and because the Script Include is “hidden” / restricted - Accessible from = This application scope only, the job can’t see it.

What to do:

  • First check the Application scope on the Scheduled Job and the scope of the Script Include. If they don’t match, that’s the issue.

  • Then fix it by either:

    • moving the Scheduled Job into the same scope as the Script Include, or

    • changing the Script Include to Accessible from: All application scopes (if that’s acceptable) or

    • creating a small public wrapper Script Include in the job’s scope that calls the hidden one.

Also make sure you’re calling it server-side like new x_scope.ScriptIncludeName().method()—scheduled jobs can’t use client-side patterns. Try all those steps and If that does not fix send me screen shot of error msg.

 

@edmilsonsil - Please mark Accepted Solution and Thumbs Up if you found Helpful!!

MJG