Jump to content
Sign in to follow this  
Larry Schultz

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

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

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

×
×
  • Create New...

Important Information

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