Alex Feinman's Tapi wrapper problem !!! Please Help !!!

T

Tihomir Ignatov

Hi All,
I'm using Alex Feinman's TAPI wrapper, but I have the following problem:

My app is a Smart device Windows Forms application (.NET CF 1.0). I create
an other assembly for phone communication (PhoneWrapper), where I use
TapiLib.dll and reference it from MainForm. I create a second form, named
PhoneForm, which opens, when a notification (event) form TapiLib arrives in
PhoneWrapper and PhoneWrapper raises an event, which I handle in MainForm.
The new opend form (PhoneForm) handles the same event likeMainForm and here
is the problem !!!!!!! When the PhoneForm is open, the notificatins form
TapiLib don't arrive !?!?

I think that exists a problem in communication between TapiLib and GUI !!!!!
Is anyone have the same problem!
Please Help !!!


Best Regards
Tihomir Ignatov
 
A

Alex Feinman [MVP]

I'm sure the problem is that your PhoneForm is modal. Since the Tapi object
walks the list of event handlers and your main form is blocked by a modal
child, the processing stops. Try removing the main form's event handler just
before call to ShowDialog, and re-adding it after
 
T

Tihomir Ignatov

Alex said:
I'm sure the problem is that your PhoneForm is modal. Since the Tapi
object walks the list of event handlers and your main form is blocked by
a modal child, the processing stops. Try removing the main form's event
handler just before call to ShowDialog, and re-adding it after


Hi
In PhoneWrapper we start new thread every time when arrives the
notification from TapiLib. In that thread PhoneWrapper raises an event,
which is handeled in MainForm.And in the PhoneForm, after we show it.In
the MainForm we remove event handler just before call to ShowDialog, and
re-add it after disposing of the ShowDialog.In this way we solve the
previous problem and while the PhoneForm is open, the notificatins
fromTapiLib arrive .It's now ok.But we have another problem - we can not
access any form's (PhoneForm) control while it is open.We try to access
them(controls) by using Invoke method of the form.


Regards
Tihomir Ignatov
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top