开发者

How to set Intent result in Layout

开发者 https://www.devze.com 2023-01-12 16:39 出处:网络
friend\'s, I there any possibility to bind the result of Intent class in xml layout, i\'m doing it so for sending mail,i\'m using below code for sending mail in

friend's, I there any possibility to bind the result of Intent class in xml layout,

i'm doing it so for sending mail,i'm using below code for sending mail in

Intent sendIntent = new Intent(Inte开发者_如何学Cnt.ACTION_SEND);
                sendIntent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
                sendIntent.putExtra(Intent.EXTRA_EMAIL,
                new String[] { "info@blacksheep.com" });
                sendIntent.setType("vnd.android.cursor.dir/email");

when i use the above code it opens a new page,but i need it to be in the layout alone. How can i get it.

Thanks in advance.


when i use the above code it opens a new page,but i need it to be in the layout alone. How can i get it.

You cannot do that, sorry. You are opening an activity from another application (whatever the user chooses to handle your ACTION_SEND request) -- it controls the presentation, not you.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号