From 92adcb027e3ecdf69095828fb02a41b07f64aeea Mon Sep 17 00:00:00 2001 From: Markus Quaritsch <markus.quaritsch@tugraz.at> Date: Tue, 11 Oct 2016 16:07:35 +0200 Subject: [PATCH] avoid opening non-json files --- VECTO/GUI/MainForm.vb | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/VECTO/GUI/MainForm.vb b/VECTO/GUI/MainForm.vb index 787f90631e..47f43c18a9 100644 --- a/VECTO/GUI/MainForm.vb +++ b/VECTO/GUI/MainForm.vb @@ -581,6 +581,10 @@ Imports VectoAuxiliaries f = LvGEN.SelectedItems(0).SubItems(0).Text f = FileRepl(f) + If Path.GetExtension(f) <> VectoCore.Configuration.Constants.FileExtensions.VectoJobFile Then + MsgBox("Job File " + f + " can not be opened in Job Editor. Try importing the file.") + Exit Sub + End If If Not File.Exists(f) Then MsgBox(f & " not found!") Else -- GitLab