how can i get email from facebook connect

Jan 11, 2010 at 1:32 PM

I am using facebook connect in VB. I  am able to access all the information of user but not email address How can I get his email Address

I am using facebook developer kit 3.0

Jan 12, 2010 at 6:48 AM

Jan 21, 2010 at 3:54 AM

Facebook has allowed us get user email address


Jan 21, 2010 at 5:03 AM

Thanks anhmytl for your reply, wana ask one more thing.       

<script src="" type="text/javascript"></script>

       <fb:login-button v="2" size="medium" onlogin="window.location.reload();">Connect with Facebook</fb:login-button>

using above I was able to promt the login screen hrough which I can get normal user info

      _connectSession = New ConnectSession(APPLICATION_KEY, SECRET_KEY)

     _facebookAPI = New Api(_connectSession)

     Dim user As user = _facebookAPI.Users.GetInfo()

     lblStatus.Text = String.Format("Signed in as {0} {1} {2}", user.first_name, user.last_name, user.birthday)

here I can get user's normal information. Now as you are talking about extended permission.

What to do to take extended permission from user..?

Jan 21, 2010 at 3:47 PM

The email changes are one in a string of upcoming Facebook api changes that lack support in this toolkit.  It would be so wonderful if the developers of the toolkit could have a presence here to comment on the roadmap for the FDK.

In the meantime, there are some workarounds.  Of course a month from now the Notifications.SendEmail method will stop working, and you will need to get either the proxied email address or the real email address from Facebook and send the emails yourself using System.Net.Mail

There is a workaround for these new Facebook api methods.  You can call Facebook.Rest.Api.SendRequest with a dictionary of parameters and get an xml response with the result.  I've used this to test out the new Dashboard api methods, and it does work.  For example:


                var pd_b = new Dictionary<string, string>();
                pd_b.Add("method", "Dashboard.getCount");
                pd_b.Add("uid", userID);
                var result = api.SendRequest(pd_b);

will get the count of Dashboard notifications for a given user for your app.  Beneath the covers, many of the FDK api methods use this approach.  It is not pretty and you have to parse the xml coming back, but at least you aren't high and dry and having to look at other options like php :(


Jan 22, 2010 at 5:24 AM

Hi nishantgauttam,

If your application requires a user's email address, you have to prompt the user for the email extended permission to allow the application uses user's email address.

Sorry about my poor english


Jan 27, 2010 at 7:20 AM

hello ,

I tried below code (ref:


<script src="" type="text/javascript"></script>

<script> //FB.init({ apiKey: 'YOUR_API_KEY' });

FB_RequireFeatures(['XFBML', 'Connect'], function() {

FB.init("YOUR_API_KEY", null, {

permsToRequestOnConnect : "email",



problems- a) why there is comma after email

b) why null is passed

c)  the paranthesis({) written after null is not closed

d)why FB.init(   ............  is not closed

I tried all things nothing works..

Jan 27, 2010 at 8:41 AM
Edited Jan 27, 2010 at 8:43 AM

Try this:

<script type="text/javascript">
        FB_RequireFeatures(['XFBML', 'Connect'], function() {
            FB.Facebook.init('YOUR_API_KEY', 'xd_receiver.htm', {  permsToRequestOnConnect: 'email'  });

Jan 27, 2010 at 9:02 AM

that is also not working any way I tried below code

<fb:prompt-permission perms="email">Would you like to receive email from our application?</fb:prompt-permission> 

It works but only if I am already logged in facebook in same browser somewhere I read also that few XFBML tag require a session


at this console page i tried my code- <fb:prompt-permission perms="email">Would you like to receive email from our application?</fb:prompt-permission>, it worked only if I am logged in (i have a session).

But here problem is Cant same code prompts for login first if no session is there and then asks for email permission? any solution..?  OR how can I check that if session is present then prompt for email permission else prompt for login first..??