public void Edit(DataGrid dataGrid) { if (Bat.IsBat(dataGrid, out Bat bat)) { Process.Start("notepad.exe", bat.Path); } }
public void Run(DataGrid dataGrid) { if (Bat.IsBat(dataGrid, out Bat bat)) { Process.Start(bat.Path); } }
public void OpenDestinationLocation(DataGrid dataGrid) { if (Bat.IsBat(dataGrid, out Bat bat)) { var location = Path.GetDirectoryName(bat?.Destination); if (location != "") { Process.Start(location); } } }
public void Delete(DataGrid dataGrid) { if (Bat.IsBat(dataGrid, out Bat bat)) { File.Delete(bat.Path); bats.Remove(bat); dataGrid.Items.Refresh(); } PopulateDataGrid(dataGrid, _outputFolder); }