Skip to content

Commit 4b41b09

Browse files
committed
Refuse to start recording without a file name
1 parent 760f1aa commit 4b41b09

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

mainwindow.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -233,6 +233,11 @@ void MainWindow::startRecording() {
233233
// determine the experiment number block
234234
// scan the path for %n/%1 and %b/%2
235235
recFilename = ui->locationEdit->text();
236+
if (recFilename.isEmpty()) {
237+
QMessageBox::critical(this, "Filename empty", "Can not record without a file name");
238+
return;
239+
}
240+
236241
int pos_n = recFilename.indexOf("%n");
237242
if(pos_n != -1)
238243
recFilename.replace(pos_n, 2, QString::number(ui->experimentNumberSpin->value()));

0 commit comments

Comments
 (0)