Skip to content

Commit

Permalink
Merge pull request #5 from KIOS-Research/SPLACE-v2.1
Browse files Browse the repository at this point in the history
add option for savename
  • Loading branch information
Mariosmsk authored Aug 10, 2019
2 parents a7f52af + 5eb6f96 commit 6b1c187
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
10 changes: 6 additions & 4 deletions SPLACE.m
Original file line number Diff line number Diff line change
Expand Up @@ -1221,9 +1221,11 @@ function export_sensors_Callback(hObject, eventdata, handles)
% handles structure with handles and user data (see GUIDATA)
load([pwd,'\RESULTS\','w.report'],'w','-mat');

% [~, repname] = fileparts(handles.B.InputFile);
[file,path] = uiputfile('*.txt');

[~, inpname] = fileparts(handles.B.InputFile);
% name = [repname, 'Sensors_report.txt'];
name = 'Sensors_report.txt';
name = [path, file];
f = fopen(name, 'w');

for i=1:length(w)
Expand All @@ -1233,9 +1235,9 @@ function export_sensors_Callback(hObject, eventdata, handles)
fprintf(f, '\n');

fprintf(f, '----------------------------------------------------');
fprintf(f, '\n');
fprintf(f, '\n');
fprintf(f, '\n\n');

fprintf(f, ['Network file: "' inpname, '.inp"\n\n']);
fprintf(f, 'Report by S-PLACE Toolkit.');

fclose(f);
Expand Down
2 changes: 2 additions & 0 deletions Sensors_report.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,6 @@ mean = 17926.36 max = 60480.00 NodesID: 11 22 31

----------------------------------------------------

Network file: "Net1_Rossman2000.inp"

Report by S-PLACE Toolkit.

0 comments on commit 6b1c187

Please sign in to comment.