Create a new SystemState Property in C#? - Windows Mobile Development and Hacking General

My goal is this: I have an external database with (company-) contacts as a SQLCE database. Since there are over 1000+ contacts in that database, I don't like the idea to 'load' all of them in my outlook. So when there's an incoming call I check if it is an outlook contact, if not I like to search the external database (by phone number) and create a contact 'on the fly' (NOT to be stored in poutlook!)
I 'detect' a new incoming call like this:
private SystemState _phoneIncomingCall = new SystemState(SystemProperty.PhoneIncomingCall);
_phoneIncomingCall.Changed += OnPhoneIncomingCallChanged;
This works like a charm. In the OnPhoneIncomingCallChanged method I check if the (new SystemState(SystemProperty.PhoneIncomingCallerContact)).CurrentValue is null. This too is working Now I would like to 'alter' the PhoneIncomingCallerContact with a contact I lookup in the other database using the incoming number. I imagine I should create a new contact and 'rethrow' the PhoneIncomingCallerContact.
The "OnPhoneIncomingCallerContact" function in the dialer should be triggered and the 'altered' contact information displayed.
Key question: can I create a SystemState(SystemProperty.PhoneIncomingCallerContact) "State and Notifications Broker" message?
And off course if so: how to do it in C#?
Another approach might be to 'unhook' the default phone application, get the incoming call and 'hook' the phone application back when I decide to take the call or reject the call?
Again: Is it possible and how to do it in C#?
Your help is appreciated...

Answered @ Windows Mobile Developer Center
If anyone cares

lextendo said:
Answered @ Windows Mobile Developer Center
If anyone cares
Click to expand...
Click to collapse
Thanks for sharing.

Related

Phone application cprog.exe

Hi,
I want some information about default phone application cprog.exe.
I want to know how does it communicate with outlook and other application.
I guess most probably it should be via message posting.
But, unfortunately wheni tested the same with spy running on cprog and then i called a contact from outlook contacts.
I see many messages posted to cprog but I found no message or Parameter(WPARAM/LPARAM) to cprog that contains the number to call.
can anyone help me out to get information how to fetch that number? the number passed to phone/cprog.exe from contact.
The same thing i need for sddialer.exe that after matching the sound tag, how it informs cprog that which number to call?
Please help! I am looking these since long...
Good Luck
Best of luck trying to find any doco on cprog (if you do, please post back here!).
If you have a look at this thread you may find what you are looking for (at least how to initiate a call from the PC is there):
http://forum.xda-developers.com/showthread.php?t=295585
Look for LINE_REQUEST message
There a two ways, that an application can make a call; using tapiRequestMakeCall or lineMakeCall. tapiRequestMakeCall is by far the simplest to use. Examples of their use can be found in two sample cellcore progams available from microsoft, CeDialer, and HelloTapi. You could try this and see which produces messages simular to outlook. I'll guess that it's HelloTapi (tapiRequestMakeCall).
When an application uses tapiRequestMakeCall a LINE_REQUEST message is sent to the call-control application. This application must then call lineGetRequest to get information on the request. It then must execute the request.
See the remarks on the lineRegisterRequestRecipient page at microsoft
http://msdn2.microsoft.com/en-us/library/ms736043.aspx
I wish there was a similar Hello USSD example for the lineSendUSSD API. There's very little information on it... No one seems to be able to capture the responses past the first call.
oops missed part of your question
After the call app places the call, it should get a series of messages, mostly LINE_CALLINFO and LINE_CALLSTATE. The messages contain a handle for the call. Once you have the call handle you should be use the lineGetCallInfo and lineGetCallState functions to get info about the call. I think lineGetCallInfo includes the number that was called. The callstate typically goes through dialling, progressing, and then connected. I believe your not supposed to use the call handle until after a LINE_REPLY message is sent, saying the call didn't fail. If there are problems perhaps you should wait a short time.
To find out more about the messages, you could play with the CeDialer sample. It's linecallbackfunc looks at the messages, it would be easy to put in a few logging statements to see what's in each message. It think CeDialer will only get messages for inbound calls, and calls that it originated. (not ones by cprog.) Although you should check to be sure that I'm correct.
Good luck! Please, let us know whatever you might find out.
Hi,
I will look into this and post reply according As soon as possible.
Thanks
Where i can find the original cprog.exe to install in my non phone PDA? it's the dialer for voip.
Many thanks

Get the incoming call's phone number (Caller ID)

Hi all,
How can I catch the incoming call's phone number (Caller ID) using the MFC?
If I use .NET there is SystemState and the SystemProperty PhoneIncomingCallerNumber. But what is similar with MFC?
Has anybody maybe a code snippet?
Joline
For WindowsMobile 5.0 and above you can read it from the registry.
Don't remember the exact reg key... but look in the SDK for:
SN_PHONEINCOMINGCALLERNUMBER_ROOT
SN_PHONEINCOMINGCALLERNUMBER_PATH
SN_PHONEINCOMINGCALLERNUMBER_VALUE
Best regards
Øystein
Thanks. This works.
I wrote a program which uses notifications and catches an incoming call. To see if that works the program opens a message box if there is an incoming call. But regrettably first I get the notification from the system and AFTER hang up the message box from my program appears.
What can I do that my program catch the call BEFORE all other programs notify this (e.g. to change the ring tone depending on the caller id)?
Joline
IMHO iits not so easy. You must use TAPI library and/or directly Ril.
Where can I find useful information about how to use TAPI and RIL (maybe with examples)?
Joline
For RIL exists only fragmentary informations - good source is forum http://www.teksoftco.com/forum/viewforum.php?f=15.
For TAPI examples search Windows Mobile SDK.
I need the same phone number catching in PHP
Hi ,
I need to generate the popup using PHP while the call is landed in our phone.
how can we do this?
Thanks and Regards,
JayarajMohan.J

Contact Searcher v4.0 ADDED: NEW SOFTWARE on 19/11/07

Many contacts info is stored in your handset.
When you need to call someone of the contacts , and you should
not remember their name or number clearly.
Your ppcs embedded contacts list software support searching by
their name or number only.
In this software, you can search the contacts by their any
property values, or searching in all of their property
information.
You can find them easily with this software. You can find them by
enter a word or a tip info of the contacts.
In the search by listbox, choose a condition.
If you choose all, the software will fix all of the contacts
property.
if you choose company the software will fix all of the
contacts company name property.
For example, you choose company, and in the is textbox, you
input microsoft or micro,
this software will select the contacts which company name property
is microsoft or micro for you.
For example, you choose all, and in the is textbox, you input
California,
this software will select the contacts which all properties
values have California string.
Not forget, click the button search, it will do searching.
The listbox will appeared the searching results after you click
search.
If want to call or sms someone of them, click it in the listbox
or move the cursor to him and
click the call & sms button.
Credit to SuYoG from ipmart
GET IT HERE
New Sofware: Software Deploy
Much faster
Much more functions
Input any chars of your ppc contacts list, such as their name, Company, address, and other all. It can find them directly and it support you call, sms, or email them.
Get it HERE
Nice effforts.
But it takes as much time as the standard inbuilt "search" program takes. In case we can improve the speed then this program would be worth your efforts..good luck
ADDED: New Software: Software Deploy
Much faster
Much more funtions
input any chars of your ppc contacts list,
such as their name, company,address, and other all.
it can find them directly.
and it support you call, sms, or email them.
Get it in the first post.
Any chance of a screenshot and a zip file?
Social networking sites are barred at my office
Thanks,
Thanks, will try this out.
I dont notice any significant improvement in the speed. Nerthless, good efforts..

Group contacts

In the Sim manager there is an Edit Group but I cannot find anything that will let me add a group, is there anything that will let me group contacts?
My purpose is to be able to just select the group when I am sending an SMS and it will send the SMS to all the members of that group instead of me selecting all the contacts.
Thanks!
Someone has mentioned about PowerSMS on another forum but it is not free, anyone who has another suggestion?
TIA
Inesoft Phone
Dialer
Dialer makes the usage of the main phone features easy and quick: dial a number, send a message, search a person or add a new contact to your address book. Save your time using Inesoft Dialer on your Windows Mobile phone.
Video Tutorial
One touch
Buttons are big enough and the interface is designed so that you could type with fingers and not to use stylus. Make a call, send a new SMS, add any information about the contact in one touch
T9 Search
If you have a lot of contacts, use the search feature to quickly find a certain person. The information is searched through all the main info fields and through the comments or notes. That's why it is very easy to find a contact when you remember information partly
Visualization
Upload a photo for the each contact in your address book. The photo will be displayed when you receive or make a call. Photos will be also displayed at your Favorite list, after the successful search of the contact is fnished.
Connection notification
Making a call your phone will give a light vibro-signal, notifying you about the successful connection. Thus you do not need to look at the display and check the connection. Double vibro-signal will let you know that the number you are trying to reach is busy.
http://www.inesoft.com/eng/index.php?in=phone_dialer.html
Don't just purchase the software because I referred this application, take the trial. I haven't fully tried this application in regards to categories...
I use GroupSMS, which is free:
http://forum.xda-developers.com/showthread.php?t=354164
Works great on the Xperia. You determine the people in a group by editing their contact details and selecting their 'categories'.
You can't do this from manilla if you use it, you have to go to the old windows mobile contact view.

Communicating with device

I'm working on a location based app that would request the phone to send its GPS location. My question is, what are the available methods for requesting the location from the device? My first choice was HTTPD but the device IP is unreachable from the world (sprint). My second choice is SMS and have the phone intercept the messages. If it sees a location request SMS then it would respond to a web service with its current location.
Is this a reliable method?
chris
Looks like MS My Phone uses SMS to request phone data... interesting.
Location request:
SkY!AVEjDy2DGyMCE6RO0qhs56aR1/zf42OXBlbdErz6sVTLW6iHFk+wQUhRX6aSEDkI0w==
Ring request:
SkY!AZbZmdMB6eVOig9Y5Ol6QtCQZAVU8XFZLi19k95Cqzn14CZ+qKuUi+2ha3VFqbRdXA==
Lock request: pin 1234, text Chris
SkY!AYDmzGeCMrT8NeDWmn5QaK96Jvsv0mQZIqEgwzvwE35ZCuBZea4M349kMwBkjVV63Y0ROvV+okapsl7UnzqcJBU=
You would think that MS would filter these texts out of the sync process...
The Ring request worked and GPS location failed (btw, the GpsSample from the SDK does not work either). So no MS I don't want to pay 4.99$ for your non-working premium services.
Sky Command Received | Command Locate (ID 2) | Request Id 22815
Sky Command Received | Command Ring (ID 1) | Request Id 22816
I wish the app was .NET like bing so I can reflect on it.
\Application Data\Microsoft\My Phone\Config.dat contains some service end point info. I would like to get the WSDL of those.
I'm curious about HKLM\init\Myphone\OEMOverride = 1.
This is great MS, due to your SMS interceptor I can't send myself any SMSs that start with 'SkY!'.
I tried resending the above SkY requests to my phone. The only thing that happened was the phone backlight came on (the SMS was not visible) and \Application Data\Microsoft\My Phone\MyPhoneLog.txt got an entry appended but the request was not valid. keep in mind that I had to uninstall the MyPhone app and use the MyPhone web site to send out those SMSs so that they would not get intercepted by MyPhoneService.dll.
I stopped the SBB0: service but the SMS still got intercepted. I didn't stop the Notification though: NamedEvents\MyPhoneRuntimeStartRuntime (if that's the right notification).
I guess the next step would be to write a .NET SMS interceptor to see if it will intercept the SMSs or not.
it looks like the interception is done using MAPI Rules which I assume is processed before MessageInterceptor and it looks like the SMS cannot be replayed...
List of commands:HKEY_LOCAL_MACHINE\Software\Microsoft\My Phone\SkyServices\SkyCommands

Categories

Resources