I am developing an application, i want to know how to achive forget password scenario in iPhone.
When user forget their password then I have a button in my app when i click on it UIAlertView open in which i have a textfield, user must enter their email address and the password get mail on that mail id.
How can I do that I have define a action for button this is the code:
-(IBAction)forgetpassword:(id)sender
{
UIAlertView *av = [[UIAlertView alloc]initWithTitle:@"Forget Password" message:@"Please Enter your Email address " delegate:self cancelButtonTitle:@"Cancel" otherButtonTitles:@"OK", nil];
av.alertViewStyle = UIAlertViewStylePlainTextInput;
[av textFieldAtIndex:0].delegate = self;
[av show];
}
but what i need is just require the code to which i can use and mail the password to the email id which user will entered.
just add delegate
MFMessageComposeViewControllerDelegateto the .h file and then use this code when you want to email and also add frameworkMessageUI.frameworkin the projectand this bellow method is delegate method of
MFMessageComposeViewControllerDelegateyou can also use SKPSMTPmessage web-service for send e-mail
i hope this help you…