private void addDealToZZDatabaseFromTextFile() { openFileDialogProspectusTextFile.ShowDialog(); string filePath = openFileDialogProspectusTextFile.FileName; string zzDbConnString = SPFileManagementUtils.ConnectionStringZZDatabase; SPDatabaseUpdateTools.AddDealFromTextFileToDatabase(filePath, zzDbConnString); MessageBox.Show("Finished adding deal to database.", "Done"); }
private void buttonDelete_Click(object sender, EventArgs e) { string cusip = tbCusip.Text.Trim(); System.Collections.Generic.List <string> tablesInDatabase = SPDatabaseUtils.GetSPDatabaseListOfDealTables(); SPDatabaseUpdateTools.DeleteCusipRecordFromSPDatabase( cusip, tablesInDatabase, TargetDatabaseConnectionString); MessageBox.Show("Finished deleting Cusip from records.", "Done"); Application.Exit(); }
private void addAllDealsToZZDatabaseFromFolder() { folderBrowserDialogFolderWithTextFiles.ShowDialog(); string folderPath = folderBrowserDialogFolderWithTextFiles.SelectedPath; string zzDbConnString = SPFileManagementUtils.ConnectionStringZZDatabase; string errorLogPath = folderPath + @"\" + "Error Log.txt"; SPDatabaseUpdateTools.AddAllDealsFromFolderToSPDatabase( folderPath, zzDbConnString, errorLogPath); MessageBox.Show("Finished saving all deals from folder to ZZ Database. Error log " + "was saved in same folder.", "Done"); }
private static void emptyZZDatabase() { SPDatabaseUpdateTools.ClearAllDealDataFromZZDatabase(); MessageBox.Show("Finished clearing all deal data from ZZ database.", "Done"); }