private void btnLogin_Click(object sender, EventArgs e) { if (IsLogin != true) { Login frm = new Login(); frm.ShowDialog(); if (IsLogin == true) { lblAccountName.Text = FBclass.GetUserName(Settings1.Default.AccessToken); string imgURL = string.Format("http://graph.facebook.com/{0}/picture", FBclass.GetUserID(Settings1.Default.AccessToken)); imgAccount.ImageLocation = imgURL; btnLogin.Text = "Logged In"; } } }
private void Form1_Load(object sender, EventArgs e) { btnImages.Hide(); if (IsLogin != true) { btnLogin.Text = "Login"; Welcome frm = new Welcome(); frm.ShowDialog(); if (IsLogin == true) { lblAccountName.Text = FBclass.GetUserName(Settings1.Default.AccessToken); string imgURL = string.Format("http://graph.facebook.com/{0}/picture", FBclass.GetUserID(Settings1.Default.AccessToken)); imgAccount.ImageLocation = imgURL; btnLogin.Text = "Logged f****n In"; } } }