Problems using the Call Control API from a Windows Service

Discussion in '3CX Phone System - General' started by mondago1, Apr 27, 2012.

Thread Status:
Not open for further replies.
  1. mondago1

    Joined:
    Sep 26, 2011
    Messages:
    5
    Likes Received:
    0
    Hi

    I'm happy to provide more information if needed, but just thought I'd ask the question before going to much further with this on my own.

    We have written a program to use the Call Control API and it works fine when run as an application (on the 3CX server), but we cannot get it to run as a windows service.

    To test it further we tried taking the code from the "ActiveCalls_QueueCalls" test project and it times out indefinitely on the following line of code:

    Code:
                    Tenant[] tenantArr = PhoneSystem.Root.GetTenants();
    
    Is this a known issue? (not working from a service) Or should we persevere?

    Thanks

    Note: We're using Visual Studio 2010, 3CX v10 and 3cxpscomcpp2.dll version 1.2.19643.0
     
  2. mondago1

    Joined:
    Sep 26, 2011
    Messages:
    5
    Likes Received:
    0
    Re: Using the Call Control API from a Windows Service

    Please could someone help with this? We're no further forward. Is it possible to use the API from a Windows Service?
     
  3. SY

    SY Well-Known Member
    3CX Support

    Joined:
    Jan 26, 2007
    Messages:
    1,825
    Likes Received:
    2
    Re: Problems using the Call Control API from a Windows Servi

     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  4. mondago1

    Joined:
    Sep 26, 2011
    Messages:
    5
    Likes Received:
    0
    Re: Problems using the Call Control API from a Windows Servi

    Thank you for your reply. Unfortunately, this information we knew already. We are successfully using the API (on the server) already. What we can't do is use it in applications that run as a service. We think that this is because the API simply doesn't work in this environment. When we try basically the example project but configured to run as a service then it fails (freezes) too.

    Have there been any successful deployments of the API running as a service?
     
  5. mondago1

    Joined:
    Sep 26, 2011
    Messages:
    5
    Likes Received:
    0
    Re: Problems using the Call Control API from a Windows Servi

    Anyone? Has anyone been able to use the API from a Windows Service?
     
  6. mondago1

    Joined:
    Sep 26, 2011
    Messages:
    5
    Likes Received:
    0
    Re: Problems using the Call Control API from a Windows Servi

    Is anyone using the API for any purpose?
     
  7. SY

    SY Well-Known Member
    3CX Support

    Joined:
    Jan 26, 2007
    Messages:
    1,825
    Likes Received:
    2
    Re: Problems using the Call Control API from a Windows Servi

    3CX use this API to create components like management console (Win forms), Web components (MyPhone, Web interface), QueueManager service etc.
    Also, there are known implementations of services and components which are created by our partners and third party developers.

    I'm sure you will find the reason if you will try to debug your application

    Regards
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
Thread Status:
Not open for further replies.