Skip to content

Commit 810a2a5

Browse files
Christoph BodensteinChristoph Bodenstein
authored andcommitted
Added try-catch if no file is chosen in properties-file.
1 parent ef2de5e commit 810a2a5

File tree

3 files changed

+7
-2
lines changed

3 files changed

+7
-2
lines changed

TimeNETOptimizationEnvironment/src/toe/MainFrame.form

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -597,4 +597,4 @@
597597
</Events>
598598
</Component>
599599
</SubComponents>
600-
</Form>
600+
</Form>

TimeNETOptimizationEnvironment/src/toe/MainFrame.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,12 @@ public Component getTableCellRendererComponent(JTable table,
247247
listOfUIComponents.add(this.jSpinnerNumberOfOptimizationRuns);
248248

249249
//Reload the last File
250+
try{
250251
this.readSCPNFile(jTextFieldSCPNFile.getText());
252+
}catch(Exception e){
253+
support.log("Could not read SCPN-file!");
254+
JOptionPane.showMessageDialog(null, "Please choose a correct SCPN file!");
255+
}
251256

252257
this.switchUIState(uiState.defaultState);
253258
if (support.isIsRunningAsSlave()) {

TimeNETOptimizationEnvironment/src/toe/support.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
public class support {
4040

4141
//This Version of TimeNetExperimentGenerator
42-
public static final String VERSION = "2015-02-05";
42+
public static final String VERSION = "2015-03-19";
4343

4444
//Define some program-wide default values
4545
public static final double DEFAULT_STEPPING = 1.0;

0 commit comments

Comments
 (0)