PC Review


Reply
Thread Tools Rate Thread

Converting InTheHand SmsMessage to Microsoft SmsMessage

 
 
jonfroehlich
Guest
Posts: n/a
 
      7th Nov 2007
I would like to convert a
InTheHand.WindowsMobile.PocketOutlook.SmsMessage to a
Microsoft.WindowsMobile.PocketOutlook.SmsMessage. For example

public static Microsoft.WindowsMobile.PocketOutlook.SmsMessage
Convert(SmsMessage inTheHandSmsMessage)
{
//the inTheHandSmsMessage.ItemId is a MAPI Entry ID, which is 20
bytes
//but the Microsoft ItemId class expects an integer!
Microsoft.WindowsMobile.PocketOutlook.ItemId itemId =
new
Microsoft.WindowsMobile.PocketOutlook.ItemId((int)inTheHandSmsMessage.ItemId.Value);

Microsoft.WindowsMobile.PocketOutlook.SmsMessage msSmsMessage =
new Microsoft.WindowsMobile.PocketOutlook.SmsMessage(itemId);

return msSmsMessage;
}

However, the Microsoft version of SmsMessage expects an integer for
its constructor. I can't figure out how to convert the MAPI Entry ID
of the InTheHand SmsMessage to an integer. It's 20 bytes! Is
converting from one SmsMessage class to the other even possible? It
would really simplify things if it were...

 
Reply With Quote
 
 
 
 
Guest
Posts: n/a
 
      8th Nov 2007
Have you checked with Peter (InTheHand owner and developer)? He'd certainly
know.


--

Chris Tacke, Embedded MVP
OpenNETCF Consulting
Giving back to the embedded community
http://community.OpenNETCF.com


"jonfroehlich" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
>I would like to convert a
> InTheHand.WindowsMobile.PocketOutlook.SmsMessage to a
> Microsoft.WindowsMobile.PocketOutlook.SmsMessage. For example
>
> public static Microsoft.WindowsMobile.PocketOutlook.SmsMessage
> Convert(SmsMessage inTheHandSmsMessage)
> {
> //the inTheHandSmsMessage.ItemId is a MAPI Entry ID, which is 20
> bytes
> //but the Microsoft ItemId class expects an integer!
> Microsoft.WindowsMobile.PocketOutlook.ItemId itemId =
> new
> Microsoft.WindowsMobile.PocketOutlook.ItemId((int)inTheHandSmsMessage.ItemId.Value);
>
> Microsoft.WindowsMobile.PocketOutlook.SmsMessage msSmsMessage =
> new Microsoft.WindowsMobile.PocketOutlook.SmsMessage(itemId);
>
> return msSmsMessage;
> }
>
> However, the Microsoft version of SmsMessage expects an integer for
> its constructor. I can't figure out how to convert the MAPI Entry ID
> of the InTheHand SmsMessage to an integer. It's 20 bytes! Is
> converting from one SmsMessage class to the other even possible? It
> would really simplify things if it were...
>



 
Reply With Quote
 
jonfroehlich
Guest
Posts: n/a
 
      8th Nov 2007
I posted on the InTheHand forums but have not received a reply. I'll
email Peter directly now.

Thanks Chris,

Jon

http://csharponphone.blogspot.com

On Nov 7, 3:41 pm, "<ctacke/>" <ctacke[at]opennetcf[dot]com> wrote:
> Have you checked with Peter (InTheHand owner and developer)? He'd certainly
> know.
>
> --
>
> Chris Tacke, Embedded MVP
> OpenNETCF Consulting
> Giving back to the embedded communityhttp://community.OpenNETCF.com
>
> "jonfroehlich" <jonfroehl...@gmail.com> wrote in message
>
> news:(E-Mail Removed)...
>
> >I would like to convert a
> > InTheHand.WindowsMobile.PocketOutlook.SmsMessage to a
> > Microsoft.WindowsMobile.PocketOutlook.SmsMessage. For example

>
> > public static Microsoft.WindowsMobile.PocketOutlook.SmsMessage
> > Convert(SmsMessage inTheHandSmsMessage)
> > {
> > //the inTheHandSmsMessage.ItemId is a MAPI Entry ID, which is 20
> > bytes
> > //but the Microsoft ItemId class expects an integer!
> > Microsoft.WindowsMobile.PocketOutlook.ItemId itemId =
> > new
> > Microsoft.WindowsMobile.PocketOutlook.ItemId((int)inTheHandSmsMessage.ItemId.Value);

>
> > Microsoft.WindowsMobile.PocketOutlook.SmsMessage msSmsMessage =
> > new Microsoft.WindowsMobile.PocketOutlook.SmsMessage(itemId);

>


> > return msSmsMessage;
> > }

>
> > However, the Microsoft version of SmsMessage expects an integer for
> > its constructor. I can't figure out how to convert the MAPI Entry ID
> > of the InTheHand SmsMessage to an integer. It's 20 bytes! Is
> > converting from one SmsMessage class to the other even possible? It
> > would really simplify things if it were...



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
SmsMessage der Microsoft Dot NET Compact Framework 1 1st Nov 2008 04:15 PM
other than InTheHand Software dbmaster1443@rediffmail.com Microsoft Dot NET Compact Framework 4 31st Aug 2006 06:45 PM
smsMessage.Send MrJim Microsoft VB .NET 0 16th Feb 2006 12:00 PM
InTheHand bluetooth Paul Microsoft Dot NET Compact Framework 3 6th Dec 2005 12:54 PM
inthehand adoce.net Bruce Microsoft Dot NET Compact Framework 1 29th Oct 2003 09:06 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 07:18 PM.