How to call MMs in Windows Mobile

Source: Internet
Author: User
MMS has always been a third-party product, and Microsoft does not have an official call method. Therefore, this problem has plagued me with the need to call people. I did some research yesterday. Now let's summarize it and see if it works.

The original idea was to call tmail and add command line parameters.
I tried it.
String SMS = "-transport/" SMS/"-to/" 13918834065/"-body/" simple SMS body /"";
CreateProcess ("tmail.exe", SMS, intptr. Zero, intptr. Zero, 0, 0, intptr. Zero, intptr. Zero, new byte [128], Pi );
This
The SMS in can work, but it is not covered when it is changed to mms. It only opens the information application.Program(Tmail is run, and the following parameters are ignored)
Why is my limited wisdom unpredictable. Some people see that the parameter is not "-Transport" but "-service". I don't know why I am not working here.

so I can only take other steps. I think it is too complicated to find the path of MMS composer. Mailcomposemessage is the interface in the cemapi.
the interface of this function is a struct pointer called mailcomposefields, but the prompts for specific parameter values in msdn are no different from those for no prompts, ask Grandpa to tell Grandma to find some clues.
polap. pszaccount = _ T ("SMS");
// for MMS
polap. pszmsgclass = _ T ("IPM. MMS ");
// for SMS
polap. pszmsgclass = _ T ("IPM. smstext ");
This pszaccount and pszmsgclass are required. Where does this value come from? There are a lot of services under
HKEY_LOCAL_MACHINE/software/Microsoft/inbox/SVC in the registry. We can see SMS without MMS on the mobile phone I use (HTC S1, therefore, this MMS can only be sent through the SMS account. Then, in the msgclasses
of SMS, we found an item IPM. MMS with a value of 1. Therefore, we decided that the name of this pszmsgclass was its name. At the same time, there is also an IPM. smstext. Of course, if you use SMS, you can use it.
however, this is one, but not all mobile phones are set in this way. This is not true after reading d600, it has mms1 under HKEY_LOCAL_MACHINE/software/Microsoft/inbox/svc. Naturally, we need to write
polap. pszaccount = _ T ("mms1"); Ah, so the general practice is to read the registry key. If there is mms1, use it. If there is no mms1, read the SMS and look for the msgclass in the SMS. At least on S1. Update it slowly if you can find more mobile phones

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.