private void AddToLibaryButton_Click_1(object sender, EventArgs e) { if (ChooseFileToOpen.ShowDialog().Equals(DialogResult.OK)) { ChooseFileToOpen.Filter = "(PDF)|*.Pdf"; GetFileName = ChooseFileToOpen.FileName; Getfilesafename = ChooseFileToOpen.SafeFileName; Userdatabase.addpdfs(GetFileName, Getfilesafename); Dashboard readerpanel = new Dashboard(); addusercontrol(readerpanel, panel2); readerpanel.Reader.src = ChooseFileToOpen.FileName; } }
public void GetallPdfs() { Userdatabase.mypdfs(); if (!string.IsNullOrEmpty(Userdatabase.yourPdfFiles.Text)) { foreach (var item in Userdatabase.yourPdfFiles.Lines) { Point pt = new Point(6, 21); PdfDisplayGroupBox.Controls.Add(pdfPicsPanel); pdfPicsPanel.Visible = true; pdfPicsPanel.Location = pt; pdfNameLabel.Text = item; defualtpicture.Image = defualtpicture.InitialImage; for (int i = 0; i < Userdatabase.yourPdfFiles.Lines.Length; i++) { pt.X += 146; } } } }
private void signinButton_Click_1(object sender, EventArgs e) { Userdatabase.signingIn(new User(usernameTextBox.Text, PasswordTextBox.Text)); }
private void signupButton_Click_1(object sender, EventArgs e) { Userdatabase.AddUser(new User(FirstnameTextBox1.Text, LastnameTextBox2.Text, PasswordTextBox.Text, usernameTextBox.Text, (gender)numericUpDown1.Value)); addusercontrol(Libary, panel1); }
private void DeleteUserButton_Click(object sender, EventArgs e) { Userdatabase.DeleteUser(UserToBeDeletedbox.Text); }