Sending MMS using httpConnection (Android 2.1)

假装没事ソ 提交于 2019-12-21 06:41:50

问题


i am trying to send MMS using code sample from here. I am not sure I understand how to deal with MMSPart part and parts vars: where and how should they be filled?

Thanks in advance


回答1:


MMSPart is internal class for keeping data. Checkout this example:

Declaration:

class MMSPart {
public String Name = "";
public String MimeType = "";
public byte[] Data;
}

Example:

...
final MMSPart samplePart = new MMSPart();
samplePart.Name = "sample";
samplePart.MimeType = "text/html"
samplePart.Data = "<b>Hello !</b>".getBytes();
...


来源:https://stackoverflow.com/questions/3050749/sending-mms-using-httpconnection-android-2-1

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!