Jump to content

CallScriptImmediately only works when calc field is on the layout and................


This topic is 3354 days old. Please don't post here. Open a new topic instead.

Recommended Posts

I have a ScriptMaster Module created and installed that only uses CallScriptImmediately.

 

c_SetOrderSubStatusStaticField =

Case (

Order Sub Status = "backorder" ;
CallScriptImmediately( Get (FileName ) ; "SetNonCalcSubStatusBO" ; "BO" ) ; 
 
Order Sub Status = "willcall" ;
CallScriptImmediately( Get (FileName ) ; "SetNonCalcSubStatusBO" ; "wc" ) ;
 
IsEmpty ( Order Sub Status ) ;
CallScriptImmediately( Get (FileName ) ; "SetNonCalcSubStatusBO" ; "" )
)
 
Order Sub Status is a calc based on a relationship and is not indexable. The Script that is being called, "SetNonCalcSubStatusBO", is a plain TEXT field.
 
The CallScriptImmediately calculation (above) ONLY works when it's on the layout. I could make this a 1x1point field, however every time I move from record to record, open manage database, etc., things move slowly as it appears there's a SLOW sort of 1 to 15 records happening. This makes no sense to me, and I can't come up with what is sorting or why it's sorting. The sort dialog flashes very briefly.
 
The script being called is:
If [ Get ( ScriptParameter ) = "BO" ]
Set Field [ OrderHD::OrderSubStatusStatic ; "backorder" ]
Else If [ Get ( ScriptParameter ) = "wc" ]
Set Field [ OrderHD::OrderSubStatusStatic ; "will call" ]
Else
Set Field [ OrderHD::OrderSubStatusStatic ; "" ]
End If
  
 
Does anyone have experience with this module, or have clues or thoughts as to what may be causing this.
 
Thanks
Link to comment
Share on other sites

This topic is 3354 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.