string encoding of mms

Added by admin 8 days ago

Hi,i have run the demo project for mms MessagingToolkit.MMS, it runs well when the subject is english character, but when use some chinese character, the mms server bark "decode error", and the txt file can not display correctly when it contains chinese character.
I wonder if there are some way to set the encoding so it can work well with other language than english.
Thanks and wonderful job!


RE: string encoding of mms - Added by admin 8 days ago


Please try with the attached patch, and let us know the results


RE: string encoding of mms - Added by levilai 6 days ago

message.MessageType = MultimediaMessageConstants.MessageTypeMSendReq;
message.TransactionId = "0000000066";
message.Version = MultimediaMessageConstants.MmsVersion10;

message.Subject = "mms test";    // Subject is optional
// ContentType is mandatory, and must be last header!  These last 3 lines set the ContentType to
// application/vnd.wml.multipart.related;type="application/smil";start="<0000>"
// In case of multipart.mixed, only the first line is needed (and change the constant)
// Any string will do for the Content-ID, but it must match that used for the presentation part,
// and it must be Content-ID, it cannot be Content-Location.
message.ContentType = MultimediaMessageConstants.ContentTypeApplicationMultipartMixed;
// presentation part is written in SMIL
//message.MultipartRelatedType = MultimediaMessageConstants.ContentTypeApplicationMultipartRelated;
// presentation part has Content-ID=<0000>
//message.PresentationId = "<0008>";

when message.Subject contains chinese characters, the server just return "decoded error" as below:

<head><title>400 Decode error</title></head>
<h1>400 Decode error</h1>
<p /><hr />
Resin Professional 3.0.14 (built Tue, 05 Jul 2005 11:05:36 PDT)

RE: string encoding of mms - Added by admin 6 days ago


The attached dll should work.

The screen contains the decoded results

MessagingToolkit.MMS.dll (44.5 KB)

screen.jpg (22.5 KB)