public string CreateAlbum(string albumName, string userName) { Album album = new Album(); string pin = album.CreateNewAlbum(albumName, userName); return(pin); }
protected void ButtonCreateAlbum_Click(object sender, EventArgs e) { if (User.Identity.IsAuthenticated) { Album album = new Album(); string pin = album.CreateNewAlbum(TextBoxAlbumName.Text, User.Identity.GetUserId()); ButtonGoToAlbum.PostBackUrl = "Album2.aspx?pin=" + pin; LabelPin.Visible = true; LabelPin.Text = "Your new pin is: " + pin; ButtonGoToAlbum.Visible = true; } else { //LabelLoginError.Text = "Please login or create an account to create albums."; } }
protected void ButtonCreateAlbum_Click(object sender, EventArgs e) { if (User.Identity.IsAuthenticated) { Album album = new Album(); string pin = album.CreateNewAlbum(TextBoxAlbumName.Text, User.Identity.GetUserId()); ButtonGoToAlbum.PostBackUrl = "Album2.aspx?pin=" + pin; LabelPin.Visible = true; LabelPin.Text = "Your new pin is: " + pin; ButtonGoToAlbum.Visible = true; } else { //LabelLoginError.Text = "Please login or create an account to create albums."; } }
public string CreateAlbum(string albumName, string userName) { Album album = new Album(); string pin = album.CreateNewAlbum(albumName,userName); return pin; }