private void txtPathImportImage_DoubleClick(object sender, EventArgs e) { if (txtPathImportImage.Text != "") { Commons.ProcessStartLink(txtPathImportImage.Text); } }
private void btnCreateFileGroups_Click(object sender, EventArgs e) { string fileName = Commons.PathDatabase + "\\" + "Groups_" + schoolClass.Abbreviation + "_" + schoolClass.SchoolYear + ".txt"; TextFile.StringToFile(fileName, txtGroups.Text, false); Commons.ProcessStartLink(Commons.PathDatabase); }
private void DgwClass_CellDoubleClick(object sender, DataGridViewCellEventArgs e) { if (e.RowIndex > -1) { if (e.ColumnIndex == 6) // column of the path; opens the folder with that path { Commons.ProcessStartLink(DgwClass.Rows[e.RowIndex].Cells[e.ColumnIndex].Value.ToString()); } } }
private void txtSubFolderStorage_DoubleClick(object sender, EventArgs e) { string directory = Commons.PathImages + "\\" + txtSubFolderStorage.Text; if (txtSubFolderStorage.Text != "" && Directory.Exists(directory)) { Commons.ProcessStartLink(directory); } else { Console.Beep(); } }
private void btnCreateFileGroups_Click(object sender, EventArgs e) { if (txtGroups.Text == "") { MessageBox.Show("Prima di salvare un file, generare i gruppi"); return; } string fileName = Commons.PathDatabase + "\\" + "Groups_" + schoolClass.Abbreviation + "_" + schoolClass.SchoolYear + ".txt"; TextFile.StringToFile(fileName, txtGroups.Text, false); Commons.ProcessStartLink(fileName); }
private void txtStartLink_DoubleClick(object sender, EventArgs e) { try { if (TxtStartLink.Text.Substring(0, 4) == "http") { Commons.ProcessStartLink(TxtStartLink.Text); } else { Commons.ProcessStartLink(currentClass.PathRestrictedApplication + "\\" + TxtStartLink.Text); } } catch { Console.Beep(); } }
private void btnClassBackup_Click(object sender, EventArgs e) { if (currentClass == null) { MessageBox.Show("Scegliere la classe da tenere nel database"); return; } string imagesFolder = db.CreateOneClassOnlyDatabase(currentClass); if (imagesFolder != "") { Commons.ProcessStartLink(imagesFolder); } else { MessageBox.Show("Cartella del database della classe non trovata"); } //MessageBox.Show("Fatto"); }
private void DgwLinks_CellDoubleClick(object sender, DataGridViewCellEventArgs e) { if (e.RowIndex > -1) { try { DataRow row = ((DataTable)(DgwLinks.DataSource)).Rows[e.RowIndex]; string link = (string)row["startLink"]; Class clickedClass = db.GetClassById((int)row["idClass"]); if (link.Substring(0, 4) == "http" || link.Contains(".exe")) { Commons.ProcessStartLink(link); } else { Commons.ProcessStartLink(clickedClass.PathRestrictedApplication + "\\" + link); } } catch (Exception ex) { Console.Beep(); } } }
internal static void StartLinks(Class Class, List <string> LinksOfClass) { foreach (string link in LinksOfClass) { try { string startLink; if (link.Substring(0, 4) == "http" || link.Contains(".exe")) { startLink = link; } else { startLink = Class.PathRestrictedApplication + "\\" + link; } Commons.ProcessStartLink(startLink); } catch { Console.Beep(); } } }
private void TxtPaths_DoubleClick(object sender, EventArgs e) { Commons.ProcessStartLink(((TextBox)sender).Text); }
private void btnOpenConfigurationFolder_Click(object sender, EventArgs e) { Commons.ProcessStartLink(Commons.PathConfig); }
private void TxtPathStartLink_DoubleClick(object sender, EventArgs e) { Commons.ProcessStartLink(TxtPathStartLink.Text); }
private void picImage_DoubleClick(object sender, EventArgs e) { Commons.ProcessStartLink(Commons.PathImages + "\\" + currentImage.RelativePathAndFilename); }
private void dgwLessonsImages_CellDoubleClick(object sender, DataGridViewCellEventArgs e) { string RelativePath = Path.GetDirectoryName(currentImage.RelativePathAndFilename); Commons.ProcessStartLink(Commons.PathImages + "\\" + RelativePath); }