Reputation: 4617
I am making tweet button to send defined message to predefined user.
this code only sends tweet to my wall how to set reciever when i tweet?
Intent intent = new Intent(Intent.ACTION_SEND);
intent.setComponent(targetComponent);
String intentType = (targetComponent.getClassName().contains("com.twidroid")) ?
"application/twitter" : "text/plain";
intent.setType(intentType);
intent.putExtra(Intent.EXTRA_TEXT, "@victim Spacemarine has voted for the sake of Emperor! #becounted");
this.startActivity(intent);
my result
but it goes to my wall not to victim's as i want
Upvotes: 0
Views: 102
Reputation: 4178
If the user follows you, you will be able to send him a Direct Message. Otherwise the only solution you have is the one that you use in your question.
Upvotes: 1