Forum Discussion

jarnold615's avatar
jarnold615
Occasional Contributor
14 years ago

TC 7.5 slows to crawl after reaching particular subroutine in VBScript

Whenever I try to run the following script against the Delphi rich-client application that I test, TC always slows to a crawl when it gets to the "EditWorkRuleMinContin" subroutine.  It takes about 15 seconds just to enter a single character in a text field.  All I'm doing is adding an item in a grid, then editing it and repeating this eight more times.  I haven't encountered this problem anywhere else.  Has this kind of problem ever been reported?  I'm running Win7 Pro.




Sub WorkRuleDef


WorkRuleDef

Call OpenModule("Work Rules")


Call AddWorkRule("Work Rule 1", "WR Desc", "Minimum Time in Window")


Call EditWorkRuleMinTimeWin("Work Rule 1", "WorkSuperstate", "2:00", "fiscal", 5, "YEARLY")


Call AddWorkRule("Work Rule 2", "WR Desc", "Maximum Time in Window")


Call EditWorkRuleMaxTimeWin("Work Rule 2", "WorkSuperstate", "2:00", "fiscal", 5, "YEARLY")


Call AddWorkRule("Work Rule 3", "WR Desc", "Minimum Schedule in Window")


Call EditWorkRuleMinSchedWin("Work Rule 3", "new name", "5", "moving", 30, "YEARLY")


Call AddWorkRule("Work Rule 4", "WR Desc", "Maximum Schedule in Window")


Call EditWorkRuleMaxSchedWin("Work Rule 4", "new name", "5", "moving", 30, "YEARLY")


Call AddWorkRule("Work Rule 5", "WR Desc", "Minimum Consecutive Schedule")


Call EditWorkRuleMinConsecSched("Work Rule 5", "new name", 5, "True")


Call AddWorkRule("Work Rule 6", "WR Desc", "Maximum Consecutive Schedule")


Call EditWorkRuleMaxConsecSched("Work Rule 6", "new name", 5, "True")


Call AddWorkRule("Work Rule 7", "WR Desc", "Minimum Time after Schedule")


Call EditWorkRuleMinTimeAfterSched("Work Rule 7", "new name", 5, "nrmpay", "24:00")


Call AddWorkRule("Work Rule 8", "WR Desc", "Minimum Continuous Time Off")


 


'at beginning of next subroutine, TC slows to a crawl:


Call EditWorkRuleMinContin("Work Rule 8", "nrmpay", "24:00", "fiscal", "48:00", "YEARLY")


Call AddWorkRule("Work Rule 9", "WR Desc", "Conditional Schedule")


Call EditWorkRuleCondSched("Work Rule 9", "new name", 2, "false", "new name", 3, "true", "true", "true")


Call EditWorkRuleGeneral("Work Rule 9", "new name", "new desc")


Call DupWorkRule("Work Rule 8", "dup name", "dup desc")



End sub