PDA

View Full Version : C# wrapper, PKX_EVENT_CALL_ANSWERED not being generated



trydis
12-05-09, 04:56 PM
Hi. I tried to modify the C# sample code to work with the Pika High Level 2.5 Grand Prix SDK, but i'm facing some problems.

When i get the PKX_EVENT_CALL_ACCEPTED event i do:


PKX_TCallAnswerSettings settings;

Grandprix.PKX_CALL_Answer_25(callHandle, ref settings)
with PKX_CALL_Answer_25 defined like:



[DllImport("pikagpapi.dll")]
public static extern PK_STATUS PKX_CALL_Answer_25(TPikaHandle callHandle, ref PKX_TCallAnswerSettings settings);
and the PKX_TCallAnswerSettings defined like:



[StructLayout(LayoutKind.Sequential)]
public struct PKX_TCallAnswerSettings
{
[StructLayout(LayoutKind.Sequential)]
public struct collectCallBlock
{
public PK_BOOL enable; /* Enables/disables this feature */
public PK_UINT beforeOnHookTime; /* Specify the time (in ms) to wait before on hook. The range allowed is 100 to 5000. The default is 500.*/
public PK_UINT collectCallTime; /* Specify the time (in ms) to stay on hook. The range allowed is 1000 to 5000. The default is 1500. */
public PK_UINT afterOffHookTime; /* Specify the time (in ms) to wait after off hook to generate the PKX_EVENT_CALL_ANSWERED event. The range allowed is 100 to 5000. The default is 200. */
______
______

I'm not receiving PKX_EVENT_CALL_ANSWERED after this. What am i doing wrong?

trydis
12-05-09, 06:44 PM
PKX_CALL_Answer_25 returns PK_SUCCESS, in case someone was wondering.

vfadmin
12-06-09, 09:28 PM
Hi Trydis,

You should upgrade to the latest 2.7.x release.

There is a small API change between GP 2.5 and GP2.7.

Ordinal number were added to the end of each API call in the 2.7 stream.

trydis
12-08-09, 10:15 AM
Thank you for the reply, will try an upgrade asap