I have an Android app which has an ability to genereta some reports and gives user an option to email those reports. After chooser opens and user picks Gmail to send an email, gmail app opens and user can see a message. It would be ideal if user would not be able to see a message becouse I would like to append a little commercial below a message and would not like to allow user to delete that small commercisl. For example:
Email body:
"Some generated report.
This report was generated by XYZ APP. Download app and create your own reports!"
The part which says which app generated report should be hidden somehow so user can't see it and that small advertisement is send together with the real message.
How can I accomplish that? Thank you!
How can I accomplish that?
Send the email yourself (JavaMail, via your Web server, etc.). If the user is sending the email, via the user's own email client and the user's own email account, the user has the right to see the message and edit it as desired.
Related
I am trying to put (email-id, password), login by otp. In the 1st case, it moves to the other activity through which they have to login after verification of their mail. So here I am checking by is Email Verified method and if yes then it redirects to home page. In the 2nd case, is there any method like the 1st case for if mobile verified? Please help
You can use firebase phone auth for your 2nd case,
You can use Firebase Authentication to sign in a user by sending an SMS message to the user's phone. The user signs in using a one-time code contained in the SMS message.
You can use this once the user is not yet verified through sms, then add flag like 'isMobileVerified' on your database which you'll update after the user has verified via the code sent on his/her number.
Please see doc here
I make an application that allows users to send an email. when i use the usual procedure to send an email with intents the user is redirected to gmail app, and he can edit the mail. I would like to prevent the user from modifying the content of the email. would anyone know how to do it please?
This is too long for a comment, so I am posting the answer. The short answer is that if you rely on the user's phone as the email client, then there is no guaranteed way to prevent the user from editing the email message, because the Gmail app is out of your control. So, what you should instead do here is to use a server side webapp to send the message instead. As an example, I have used an email service (e.g. HawkHost) on the server side behind an Android app to send the message. With this setup, you can completely control what message gets sent from the user or on behalf of the user.
I am developing an app where the user can share via email (GMail app) or sms. Both methods will launch an external app that will do the work.
Since I am implementing tracking analytics that will be triggered when the email/SMS is sent, my question is how to send back or detect the status of sent email from GMail to my app. I know that it may sound like a stupid question, but I was wondering if this is possible.
how to send back or detect the status of sent email from gmail to my app
There is no requirement for the user to send the email, let alone for any email app (Gmail or otherwise) to let you know if the email was sent.
If the email is being processed automatically on some server, the server could use GCM or similar techniques to send a message to the device and your app indicating that the email was received.
I am developing an application that needs to send inside an ordinary email.
The mail must be sent with the account set up on your smartphone. Through Intent.ACTION_SEND sending the mail goes smoothly.
Is there a way to know if the email was sent and if the sending has been successful?
The mail must be sent with the account set up on your smartphone
You assume the existence of such an account, and this is not a valid assumption. Bear in mind that just because they may have a Google account (e.g., for use with the Play Store), they may not be using Gmail, and there is nothing forcing users to use their Android device for any other email.
Is there a way to know if the email was sent and if the sending has been successful?
No.
ACTION_SEND does not send email. ACTION_SEND lets the user share content of a specified MIME type. Whether the user chooses to send via email, who they send the email to, whether they change the content, whether they send the email at all, and so forth is up to the user, and your app is not informed of any of this.
I have a query. In my application, on click of a button, I start an intent to send email. I have set the "To" list, "Subject" and attachment in my coding. Now my problem is that when the email screen is shown, user should not be able modify the email contents nor should he be allowed to remove the attachment. Only he sould be able to click on "Send" button. Please help me out in this. Thanks in advance.
user should not be able modify the
email contents nor should he be
allowed to remove the attachment.
The user can do whatever the user wants. It is the user's device. It is the user's email account.
If you wish to force the email to be unmodified, you will have to send the email directly via SMTP, collecting email account information from the user.