6 Mar
2013
6 Mar
'13
7:53 p.m.
Hello, I have a .NET managed module handling calls transferred to it via dial plan. Now, I would like to maintain concurrent call count and decline the call if it has reached certain limit. What I do is, have a static variable to track this. *private static int mIntCurCalls = 0;* Then, when Run() is executed, I *mIntCurCalls++* after answering the call. I perform check *if mIntCurCalls > "max allowed calls"* then I play a message and hangup. I *mIntCurCalls--* this when call is hung up. Since last few days users have been complaining they get "busy" or "number not available" when dialing toll-free number. However, I don't see them getting the message that I have in the code. Is the method of keeping call count correct? Thanks.