RILMESSAGE dwParams problem... - Windows Mobile Development and Hacking General

I need to send message with RIL-function ( RIL_SendMsg (HRIL hRil, RILMESSAGE* lpMessage, DWORD dwOptions). For this, I need fill RILMESSAGE struct. Some of elements i get from incomming message. How i get other elements and vaild dwParams?

Thanks, I have resolved this problem.

Can you post how you solved it?
I'm looking also to more RILMESSAGE struct elements.

ril.h
alto said:
Can you post how you solved it?
I'm looking also to more RILMESSAGE struct elements.
Click to expand...
Click to collapse
is that what you need?
http://www.xs4all.nl/~itsme/projects/xda/ril/ril.h
bigmac

Re: ril.h
bigmac said:
alto said:
Can you post how you solved it?
I'm looking also to more RILMESSAGE struct elements.
Click to expand...
Click to collapse
is that what you need?
http://www.xs4all.nl/~itsme/projects/xda/ril/ril.h
bigmac
Click to expand...
Click to collapse
Thanks, this header file has much more information.
What I'm looking for is to get data about communications event like in/out voice calls, in/out gprs sessions, in/out sms messages, I get some data in the 'tstril' sample for incoming sms messages by catch this event and parse it with the 'RILMESSAGE' structure.
I'm looking for info about the other events structure data that it’s missing in the struct in the h file.

Related

Need help for Message Interception (WM6 / VB.Net)

I want to use the MessageInterception Handler, but when I add the following code:
Imports Microsoft.WindowsMobile.PocketOutlook
Imports Microsoft.WindowsMobile.PocketOutlook.MessageInterception
Public Class Form1
'---used for intercepting SMS messages---
Private msgInterceptor As MessageInterceptor
Click to expand...
Click to collapse
Visual Basic reports an error:
Error 1 Reference required to assembly 'Microsoft.WindowsMobile, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' containing the implemented interface 'Microsoft.WindowsMobile.IApplicationLauncher'. Add one to your project. C:\IPSMS\Form1.vb 63 31 IPSMS
Click to expand...
Click to collapse
Can someone help me with this?
Solved: I have forget to add Windows.Mobile as a reference.
It´s not working:
'---used for intercepting SMS messages---
Private msgInterceptor As MessageInterceptor
Private Sub SMSInterceptor_MessageReceived(ByVal sender As Object, ByVal e As MessageInterceptorEventArgs)
MsgBox("message received")
End Sub
Click to expand...
Click to collapse
If I send a SMS to the mobile the Sub isn´t executed.
edit: I have added
msgInterceptor = New MessageInterceptor(InterceptionAction.NotifyAndDelete, True)
AddHandler msgInterceptor.MessageReceived, AddressOf SMSInterceptor_MessageReceived
Click to expand...
Click to collapse
to the OnLoad Section. It´s working now.

Sprint MMS Block Workaround [Idea for Developers]

If you haven't already heard Sprint has denied access to the MMS service with PPC devices. We used to get around this by installing Arcsoft MMS but even that won't work anymore.
Since the only way to send MMS or PictureMail is through E-Mail I was wondering if it's possible to develop an application to make this an easier process. The application will ask for phone number or contact name, the carrier, the media to be sent, the subject, and the message. With all that information it'll compose an e-mail to [phonenumber]@[carrier'saddress].com
-- Edit --
no2chem is working on a workaround. see his post on ppcgeeks from more info.
http://forum.ppcgeeks.com/showthread.php?t=19122
A simple workaround...is to send the pic to urself...([email protected]) and once u receive it jus forward the url to people u wanna send it to. thaz wut they get anyway. that way you dont have to worry about different carrier mms addresses.
Others have a working MMS application installed through their carriers or none PPC Sprint phones. The beauty of MMS is the fact that it's so simple to send and retrieve the media. If it wasn't for that then we can just e-mail each other photos and skip the whole process.
this sounds like a great idea, until sprint lets us use it again, which i don't see happening
malibu_23 said:
A simple workaround...is to send the pic to urself...([email protected]) and once u receive it jus forward the url to people u wanna send it to. thaz wut they get anyway. that way you dont have to worry about different carrier mms addresses.
Click to expand...
Click to collapse
When you say send the pic to your self at [email protected] I am assuming you mean to your 10 digit phone #@sprint.pm.com
I sent a pic to myself via hotmail and I get the message returned to me...how did you do this?
you have the address wrong.
it's [email protected][B]pm.sprint.com[/B]
initial said:
you have the address wrong.
it's [email protected][B]pm.sprint.com[/B]
Click to expand...
Click to collapse
meh, im thinking about working on this. but believe me, i have a looooot of other things on my hands.
wouldn't be that hard though, a simple app where it just asks you the photo/audio/video you want to send and the destination number... and whisks it away....
no2chem said:
meh, im thinking about working on this. but believe me, i have a looooot of other things on my hands.
wouldn't be that hard though, a simple app where it just asks you the photo/audio/video you want to send and the destination number... and whisks it away....
Click to expand...
Click to collapse
Actually thats funny, because I have been working on this lol. Building the DB right now still. Do you happen to know of any third party MMS applications? Open source or the API's?
what language are you writing it in.. I would be more then Happy to help with the dev work.
I better start preparing to bow down to you guys if you crack this
fr0st said:
what language are you writing it in.. I would be more then Happy to help with the dev work.
Click to expand...
Click to collapse
Visual Basic
i developed a beta workaround,
see
http://forum.ppcgeeks.com/showthread.php?p=192013#post192013
COUNT ME IN.. I would rather c# but I would love to help. My roommate and I both are programmers and would love to assist? You looking for some help blue?
do you have any problems with sharing your code (which I am sure in in c++) no2chem
fr0st said:
do you have any problems with sharing your code (which I am sure in in c++) no2chem
Click to expand...
Click to collapse
Frost be more then happy. As I told u in pm my last post is still pending it will shed some nfo on this. NU said he wrote in C++ not sure if he is willing to help. As far as I go I haven't wrote C in 7yrs never took on ++ though there not far off.
NUC - I will go check out what you have.
Someone posted this
Someone over on the PPCGeeks forum posted this site:
http://pktpix.com/
Seems like it might be a workaround as well as no2chem's... Just like teleflip and other SMS Gateways, but this one is international (and free)...
fr0st said:
do you have any problems with sharing your code (which I am sure in in c++) no2chem
Click to expand...
Click to collapse
no problems really, but the code is very simple and is in c#...
c++ would have been too much time...
this code does nearly all the work...
OutlookSession os = new OutlookSession();
EmailAccount ea = os.EmailAccounts[0];
EmailMessage em = new EmailMessage();
em.BodyText = textBox1.Text;
em.To.Add(new Recipient(textBox2.Text + "@" + ((carrier)comboBox1.Items[comboBox1.SelectedIndex]).address));
em.Importance = Importance.Normal;
em.Sensitivity = Sensitivity.Normal;
if (imagename != null)
{
em.Attachments.Add(new Attachment(imagename));
}
ea.Send(em);
mapi.setAccountName(ea.Name);
if (mapi.forceSyncbyName())
{
MessageBox.Show("Message Sent");
}
else
{
MessageBox.Show("Forcing sync failed, message is in your outbox.");
}
Visual Basic, I could use help new to developing on a PPC platform.
This is the function. The idea is to build a small DB because most people only have a small group of people they MMS. Easily containable in a personal config. A DB of all the carriers MMS addresses on file where users also configure a parameter of numaric class carriers with exceptions for ported numbers. Look a little like this to give you a basic idea. Like local zone 850-532-XXXX = ATT and 850-543-XXX = Sprint.
User adds contact in send list. App verify value as.
Load contact in string as send_to but we will only load first 7 chars
Open DB config file
Load DB config file
If send_to is = to a char value in config we auto address sending address as textBox.Text = string_to + carrier match
Else
Prompt string carrier_db user selects a carrier from list load to string usr_carrier
Then textBox.Text = send_to + user_carrier
Write send_to+usr_carrier to DB config
call Send_btn
EndIf
Obviously more then 1 IF statement is needed lol just a concept idea so you know what I am doing. As well an exempt file is needed for ported numbers to reference before the DB carrier file is called. Then if number is not listed we can call an ElseIf statement to carry onto the above. The grab contacts reference is also still needed.
no2chem said:
no problems really, but the code is very simple and is in c#...
c++ would have been too much time...
this code does nearly all the work...
OutlookSession os = new OutlookSession();
EmailAccount ea = os.EmailAccounts[0];
EmailMessage em = new EmailMessage();
em.BodyText = textBox1.Text;
em.To.Add(new Recipient(textBox2.Text + "@" + ((carrier)comboBox1.Items[comboBox1.SelectedIndex]).address));
em.Importance = Importance.Normal;
em.Sensitivity = Sensitivity.Normal;
if (imagename != null)
{
em.Attachments.Add(new Attachment(imagename));
}
ea.Send(em);
mapi.setAccountName(ea.Name);
if (mapi.forceSyncbyName())
{
MessageBox.Show("Message Sent");
}
else
{
MessageBox.Show("Forcing sync failed, message is in your outbox.");
}
Click to expand...
Click to collapse
"EmailAccount ea = os.EmailAccounts[0];" So you change the 0 to whatever number the email account on your phone is right? 0 being outlook... and i'm guessing an autonumber from then on?
Also what namespaces and assembly references are you using?
fr0st said:
"EmailAccount ea = os.EmailAccounts[0];" So you change the 0 to whatever number the email account on your phone is right? 0 being outlook... and i'm guessing an autonumber from then on?
Also what namespaces and assembly references are you using?
Click to expand...
Click to collapse
well, that was code for the quick beta.
Microsoft.Windowsmobile namespace, look into it =) its quite nice.
EmailAccounts[0] would pick the first e-mail account, it only can use e-mail accounts in outlook. i used[0] as a quick hack and slash test, but now i let them choose which e-mail they want to use, , you would just enumerate thorugh all the email accounts,
foreach (EmailAccount ea in os.EmailAccounts)
{
....
}

app for WM6.1 sending sms

Hi
some one can help me make one program for send predefined sms quickly
I lake some like that:
when I press a button, program send one sms for one number with button text...
I make this with Basic4ppc but I dont know how I make the functions for send sms...
some one can help me make one program for make some like that?
if I need used other program no problem...
best regards
Never used basic4ppc, but I'd guess it would be possible to open a shortcut/program... That would allow you to use something like VJPhoneTools to send the message rather than interfacing with TMail.
E.G.
Code:
"\Program Files\vijay555\VJSMS.exe" "number" -body "text"
Might be faster that way...
Alternatively, if basic4ppc can inteface with the .NET CF, you can use Microsoft.WindowsMobile.Telephony to send an SMS.
EDIT: looking at the documentation, this may be more helpful!
Code:
Sms.New1("987-654321","This is the message body.")
Hi
I try make other program how I copy from other forum but it give me an error...
Sub Globals
'Declare the global variables here.
End Sub
Sub App_Start
Form1.Show
End Sub
Sub Button1_KeyPress (key)
sms.new1 ("965542750","teste")
End Sub
I dont understand anythink of basic I only use C but basic4ppc only use basic
I dont need declair "sms.new1 "? if yes where?
regards
I have no idea with this... But, I thin maybe this:
Code:
Sub Globals
'Declare the global variables here.
End Sub
Sub App_Start
Form1.Show
Sms.new1
End Sub
Sub Button1_KeyPress (key)
Sms.new1 ("965542750","teste")
End Sub
now I have an error on "sms.new1" :s
Ah!
I think I have it!
You'll need to add the libraries...
Tools->Components->Add Dll, and then click on the "outlook.dll"
Then, Tools->Add object, and select "SMSMessage", enter a name (E.G. Sms) and then use the code as per earlier (Sms.new1 ("965542750","teste")
)
Hi
problem solved... I need put this DLL to work
thanks
filjoa said:
Hi
problem solved... I need put this DLL to work
thanks
Click to expand...
Click to collapse
No problem... And, now I know some basic4ppc!
Now that SMS while driving is finally illegal here, I made a bunch of these .LNKs
Paste this into a *.TXT file, update the TO and BODY and rename to *.LNK.
20#"\Windows\tmail.exe" -service "SMS" -to "021xxxxxxx" -body "Can I call now?"
Click to expand...
Click to collapse
No Vijay or programing skills needed
I link them to WM5NewMenu so I can easily choose the one I want.
You may want to have custom icons. Not sure how to do this, maybe do like supbro and make .EXEs then use Resource Hacker to change the icon...
evojulz said:
Now that SMS while driving is finally illegal here, I made a bunch of these .LNKs
Paste this into a *.TXT file, update the TO and BODY and rename to *.LNK.
No Vijay or programing skills needed
I link them to WM5NewMenu so I can easily choose the one I want.
You may want to have custom icons. Not sure how to do this, maybe do like supbro and make .EXEs then use Resource Hacker to change the icon...
Click to expand...
Click to collapse
I think that requires you to confirm/send the message?
It's not that difficult in basic4ppc, or in C#/VB .NET CF
If you set tmail with -sync it will automatically send the message for you without needing confirmation to send.
h4waii said:
If you set tmail with -sync it will automatically send the message for you without needing confirmation to send.
Click to expand...
Click to collapse
Does that work with SMS as well as email?

Problem with C#: Reading content of SMS

Hi,
a friend of mine is developing a little tool to read out content of SMS. For example when he gets a SMS notification about a missed call (when the phone was turned off) he reads out the number and displays a default windows-notification (like task-reminder).
The problem he´s got is with "MessageInterceptorEventHandler". He managed to catch the message, but he cannot read the messages content.
Has anybody experience with C# / CompactFramework or this scenario ?
regards,
Martin
IIRC, one of the arguments passed into the MessageInterceptorEventHandler is a Message object, which can be casted to an SmsMessage object, which has a String Body property that has the text of the message.
zaijian said:
IIRC, one of the arguments passed into the MessageInterceptorEventHandler is a Message object, which can be casted to an SmsMessage object, which has a String Body property that has the text of the message.
Click to expand...
Click to collapse
thanks, it worked ! Maybe we release this app here, if anybody wants the same for his mobile operator.
regards,
Martin

message2reg

I've been digging around and trying numerous examples of the message2reg.exe utility. I've found examples from ThrottleLauncher, BatteryStatus, WAD... they all seem to include the same set of files and mortscripts. It seems like the shortcuts included should cause the message2reg.exe to run and put data into the registry at ...
SMS_text = RegRead("HKLM","Software\ThrottleLauncher\Messaging\SMS","Subject")
I have all the files in \Program Files\Message2Reg\
The mortscript writes then deletes temporary registry entries in noted location above. Then it does....
RunWait("\Program Files\Message2Reg\Message2Reg.exe","SMS Refresh")
This should put the data into registry but nothing ever shows.
Also tried ...
RunWait("\Program Files\Message2Reg\Message2Reg.exe","Text Messages Refresh")
because "Text Messages" is what shows in my Messaging application (not SMS).
Eventually I want to use mortscript to get weather from google via SMS, then use message2reg to parse the SMS.
Any tips?
itesla said:
I've been digging around and trying numerous examples of the message2reg.exe utility. I've found examples from ThrottleLauncher, BatteryStatus, WAD... they all seem to include the same set of files and mortscripts. It seems like the shortcuts included should cause the message2reg.exe to run and put data into the registry at ...
SMS_text = RegRead("HKLM","Software\ThrottleLauncher\Messaging\SMS","Subject")
I have all the files in \Program Files\Message2Reg\
The mortscript writes then deletes temporary registry entries in noted location above. Then it does....
RunWait("\Program Files\Message2Reg\Message2Reg.exe","SMS Refresh")
This should put the data into registry but nothing ever shows.
Also tried ...
RunWait("\Program Files\Message2Reg\Message2Reg.exe","Text Messages Refresh")
because "Text Messages" is what shows in my Messaging application (not SMS).
Eventually I want to use mortscript to get weather from google via SMS, then use message2reg to parse the SMS.
Any tips?
Click to expand...
Click to collapse
..why don't u use regwritestring of mortscript instead of message2reg?
Let mortscript itself write the datas into registry.
How does mortscript know what to write into registry? The whole point of message2reg is to read the SMS text "behind the scenes" and put in the registry for programs like mortscript / rlotday / throttlelauncher to access. I haven't used MortScript to switch windows, copy text from window, etc.... That seems really messy and error prone, plus there are a lot of messages to repeat through.
Or can MortScript read directly from the WM messaging program now in a new version or something?
...hm I don't really know what message2reg exactly does. But mortscript is not able to communicate with the wm messaging interface.
How does message2reg know what to write in the registry? Sorry, but as i mentioned before I don't know message2reg.
But have a look here: http://forum.xda-developers.com/showthread.php?t=479076&page=3
You are not alone :-(
Well, I haven't gotten it working yet... My impression is that it writes numerous entries into the mentioned registry key (entries for subject, sender, date, body) for the most recent message in the Messaging "folder". You tell message2reg which folder to read from as a command line parameter as well as Refresh...
RunWait("\Program Files\Message2Reg\Message2Reg.exe","SMS Refresh")
RunWait("\Program Files\Message2Reg\Message2Reg.exe","Text Messages Refresh")
If you want to see the information for the next oldest message, your execute message2reg again with the "Next" parameter, and then the existing registries entries are over-written with the 2nd SMS message...
RunWait("\Program Files\Message2Reg\Message2Reg.exe","SMS Next")
cyron_at said:
But have a look here: http://forum.xda-developers.com/showthread.php?t=479076&page=3
You are not alone :-(
Click to expand...
Click to collapse
That is one of the many I read through Some people have it working so there must be some trick or missing parameter or something
Anyone get this working? Is it OS issue (WM5)?
I used it successfully in my Multiplugin:
http://forum.xda-developers.com/showthread.php?t=523015
You can see the commands I used inside.
itesla said:
I've been digging around and trying numerous examples of the message2reg.exe utility. I've found examples from ThrottleLauncher, BatteryStatus, WAD... they all seem to include the same set of files and mortscripts. It seems like the shortcuts included should cause the message2reg.exe to run and put data into the registry at ...
SMS_text = RegRead("HKLM","Software\ThrottleLauncher\Messaging\SMS","Subject")
I have all the files in \Program Files\Message2Reg\
The mortscript writes then deletes temporary registry entries in noted location above. Then it does....
RunWait("\Program Files\Message2Reg\Message2Reg.exe","SMS Refresh")
This should put the data into registry but nothing ever shows.
Also tried ...
RunWait("\Program Files\Message2Reg\Message2Reg.exe","Text Messages Refresh")
because "Text Messages" is what shows in my Messaging application (not SMS).
Eventually I want to use mortscript to get weather from google via SMS, then use message2reg to parse the SMS.
Any tips?
Click to expand...
Click to collapse
you're wrong with parameters of message2reg
they are : Next , Previous , Refresh , Reply , Details or Detail (don't remember)
Hi,
I was wondering if Message2Reg was able to get email body and/or message dates.
I successfully configured it to work with SMS and ActiveSync email but I cannot find the informations above. Any advise ?
Thank you !
This is the only info I found on this matter:
Message2Reg. Save to registry the message from the account with the number specified (to HKLM/ThrottleLauncher/Messaging/#AccountName#). Params: "account name [SMS/ActiveSync/...]" "Action [Next/Previous/Refresh/Details/Reply/Exit]". This little app is based on the MAPI api suplied here: http://www.codeproject.com/KB/mobile/PocketPCandSmartphone.aspx. If you want the sourcode of Message2Reg send me a mail and I'll send it in cumpliment of the BSD license.
Click to expand...
Click to collapse
From: http://www.throttlelauncher.com/portal/Downloads/ThrottleLauncher/092beta
damn i've really lost my mind trying to get this thing to work, seems like it does not want to wok on my device........somebody please help
i am lost at how your trying to run it.
all it does is write to the registry, you then need something to show the new reg keys.
example WAD can show REG text.

Resources