Changed file checking scheme\.

This commit is contained in:
2009-09-22 14:09:51 +00:00
parent 02334c8319
commit 857c744ee0
3 changed files with 252 additions and 224 deletions

View File

@ -1,6 +1,6 @@
# Form implementation generated from reading ui file 'MuSRFit.ui' # Form implementation generated from reading ui file 'MuSRFit.ui'
# #
# Created: Tue Sep 22 11:42:50 2009 # Created: Tue Sep 22 16:07:47 2009
# by: The PerlQt User Interface Compiler (puic) # by: The PerlQt User Interface Compiler (puic)
# #
# WARNING! All changes made in this file will be lost! # WARNING! All changes made in this file will be lost!
@ -46,11 +46,11 @@ use Qt::attributes qw(
musrfit_tabs musrfit_tabs
RUNSPage RUNSPage
RUNSAuto RUNSAuto
RunNumbers
YEAR
YEARLabel YEARLabel
BeamLine BeamLine
BeamLineLabel BeamLineLabel
YEAR
RunNumbers
RUNSMan RUNSMan
RunFiles RunFiles
Browse Browse
@ -1588,16 +1588,6 @@ sub NEW
RUNSAuto->setSizePolicy( Qt::SizePolicy(5, 7, 0, 0, RUNSAuto->sizePolicy()->hasHeightForWidth()) ); RUNSAuto->setSizePolicy( Qt::SizePolicy(5, 7, 0, 0, RUNSAuto->sizePolicy()->hasHeightForWidth()) );
RUNSAuto->setMargin( int(5) ); RUNSAuto->setMargin( int(5) );
RunNumbers = Qt::LineEdit(RUNSAuto, "RunNumbers");
RunNumbers->setGeometry( Qt::Rect(15, 25, 505, 26) );
RunNumbers->setSizePolicy( Qt::SizePolicy(0, 0, 0, 0, RunNumbers->sizePolicy()->hasHeightForWidth()) );
RunNumbers->setMinimumSize( Qt::Size(0, 23) );
YEAR = Qt::ComboBox(0, RUNSAuto, "YEAR");
YEAR->setGeometry( Qt::Rect(420, 55, 100, 26) );
YEAR->setSizePolicy( Qt::SizePolicy(0, 0, 0, 0, YEAR->sizePolicy()->hasHeightForWidth()) );
YEAR->setMinimumSize( Qt::Size(0, 20) );
YEARLabel = Qt::Label(RUNSAuto, "YEARLabel"); YEARLabel = Qt::Label(RUNSAuto, "YEARLabel");
YEARLabel->setGeometry( Qt::Rect(361, 55, 55, 26) ); YEARLabel->setGeometry( Qt::Rect(361, 55, 55, 26) );
YEARLabel->setMinimumSize( Qt::Size(0, 20) ); YEARLabel->setMinimumSize( Qt::Size(0, 20) );
@ -1610,6 +1600,16 @@ sub NEW
BeamLineLabel = Qt::Label(RUNSAuto, "BeamLineLabel"); BeamLineLabel = Qt::Label(RUNSAuto, "BeamLineLabel");
BeamLineLabel->setGeometry( Qt::Rect(127, 55, 99, 26) ); BeamLineLabel->setGeometry( Qt::Rect(127, 55, 99, 26) );
BeamLineLabel->setMinimumSize( Qt::Size(0, 20) ); BeamLineLabel->setMinimumSize( Qt::Size(0, 20) );
YEAR = Qt::ComboBox(0, RUNSAuto, "YEAR");
YEAR->setGeometry( Qt::Rect(420, 55, 100, 26) );
YEAR->setSizePolicy( Qt::SizePolicy(0, 0, 0, 0, YEAR->sizePolicy()->hasHeightForWidth()) );
YEAR->setMinimumSize( Qt::Size(0, 20) );
RunNumbers = Qt::LineEdit(RUNSAuto, "RunNumbers");
RunNumbers->setGeometry( Qt::Rect(15, 25, 505, 26) );
RunNumbers->setSizePolicy( Qt::SizePolicy(0, 0, 0, 0, RunNumbers->sizePolicy()->hasHeightForWidth()) );
RunNumbers->setMinimumSize( Qt::Size(0, 23) );
$layout43->addWidget(RUNSAuto); $layout43->addWidget(RUNSAuto);
RUNSMan = Qt::GroupBox($LayoutWidget, "RUNSMan"); RUNSMan = Qt::GroupBox($LayoutWidget, "RUNSMan");
@ -2483,7 +2483,7 @@ sub NEW
separatorAction= Qt::Action(this, "separatorAction"); separatorAction= Qt::Action(this, "separatorAction");
FileExistCheck= Qt::Action(this, "FileExistCheck"); FileExistCheck= Qt::Action(this, "FileExistCheck");
FileExistCheck->setToggleAction( 1 ); FileExistCheck->setToggleAction( 1 );
FileExistCheck->setOn( 1 ); FileExistCheck->setOn( 0 );
ManualFile= Qt::Action(this, "ManualFile"); ManualFile= Qt::Action(this, "ManualFile");
ManualFile->setToggleAction( 1 ); ManualFile->setToggleAction( 1 );
fileChangeDirAction= Qt::Action(this, "fileChangeDirAction"); fileChangeDirAction= Qt::Action(this, "fileChangeDirAction");
@ -2684,15 +2684,6 @@ sub languageChange
setCaption(trUtf8("MuSRFit GUI") ); setCaption(trUtf8("MuSRFit GUI") );
setIconText(trUtf8("MuSRFitGUI") ); setIconText(trUtf8("MuSRFitGUI") );
RUNSAuto->setTitle( trUtf8("RUN Numbers") ); RUNSAuto->setTitle( trUtf8("RUN Numbers") );
Qt::ToolTip::add(RunNumbers, trUtf8("Numbers of RUNs to fit. Multiple runs are comma separated."));
Qt::WhatsThis::add(RunNumbers, trUtf8("Numbers of RUNs to fit. Multiple runs are comma separated."));
YEAR->clear();
YEAR->insertItem( trUtf8("2009") );
YEAR->insertItem( trUtf8("2008") );
YEAR->insertItem( trUtf8("2007") );
YEAR->insertItem( trUtf8("2006") );
YEAR->insertItem( trUtf8("2005") );
YEAR->insertItem( trUtf8("2004") );
YEARLabel->setText( trUtf8("Year") ); YEARLabel->setText( trUtf8("Year") );
BeamLine->clear(); BeamLine->clear();
BeamLine->insertItem( trUtf8("LEM") ); BeamLine->insertItem( trUtf8("LEM") );
@ -2700,6 +2691,15 @@ sub languageChange
BeamLine->insertItem( trUtf8("Dolly") ); BeamLine->insertItem( trUtf8("Dolly") );
BeamLine->insertItem( trUtf8("LTF") ); BeamLine->insertItem( trUtf8("LTF") );
BeamLineLabel->setText( trUtf8("On beam line") ); BeamLineLabel->setText( trUtf8("On beam line") );
YEAR->clear();
YEAR->insertItem( trUtf8("2009") );
YEAR->insertItem( trUtf8("2008") );
YEAR->insertItem( trUtf8("2007") );
YEAR->insertItem( trUtf8("2006") );
YEAR->insertItem( trUtf8("2005") );
YEAR->insertItem( trUtf8("2004") );
Qt::ToolTip::add(RunNumbers, trUtf8("Numbers of RUNs to fit. Multiple runs are comma separated."));
Qt::WhatsThis::add(RunNumbers, trUtf8("Numbers of RUNs to fit. Multiple runs are comma separated."));
RUNSMan->setTitle( trUtf8("RUN Files") ); RUNSMan->setTitle( trUtf8("RUN Files") );
Qt::ToolTip::add(RunFiles, trUtf8("Names of data files to be fit. Multiple data files are comma separated.")); Qt::ToolTip::add(RunFiles, trUtf8("Names of data files to be fit. Multiple data files are comma separated."));
Qt::WhatsThis::add(RunFiles, trUtf8("Names of data files to be fit. Multiple data files are comma separated.")); Qt::WhatsThis::add(RunFiles, trUtf8("Names of data files to be fit. Multiple data files are comma separated."));
@ -3145,7 +3145,7 @@ sub helpAbout
sub CreateAllInput sub CreateAllInput
{ {
# TODO: Need to deliver shared parameters also # TODO: Need to automatically generage years list depending on beamline
my %All=(); my %All=();
# From RUNS Tab # From RUNS Tab
$All{"TITLE"}= TITLE->text; $All{"TITLE"}= TITLE->text;
@ -3347,7 +3347,27 @@ sub CallMSRCreate
use MSR; use MSR;
my %All=CreateAllInput(); my %All=CreateAllInput();
# Check if the option for checking for existing files is selected
my $FileExistCheck= FileExistCheck->isOn();
my $FILENAME=$All{"FILENAME"}.".msr";
my $Answer=0;
if ($All{"RunNumbers"} ne "" || $All{"RunFiles"} ne "") { if ($All{"RunNumbers"} ne "" || $All{"RunFiles"} ne "") {
if ( $FileExistCheck==1 ) {
if (-e $FILENAME) {
# Warning: MSR file exists
# my $Warning = "Warning: MSR file $FILENAME Already exists!\nIf you continue it will overwriten.";
my $Warning = "Warning: MSR file $FILENAME Already exists!\nDo you want to overwrite it?";
# my $WarningWindow = Qt::MessageBox::information( this, "Warning",$Warning);
# $Answer =1,0 for yes and no
$Answer= Qt::MessageBox::warning( this, "Warning",$Warning, "&No", "&Yes", undef, 1,1);
}
} else {
# Just overwrite file
$Answer=1;
}
if ($Answer) {
if ( $All{"FitAsyType"} eq "Asymmetry" ) { if ( $All{"FitAsyType"} eq "Asymmetry" ) {
my ($Full_T_Block,$Paramcomp_ref)= MSR::CreateMSR(\%All); my ($Full_T_Block,$Paramcomp_ref)= MSR::CreateMSR(\%All);
} }
@ -3356,6 +3376,8 @@ sub CallMSRCreate
} }
UpdateMSRFileInitTable(); UpdateMSRFileInitTable();
} }
}
return $Answer;
} }
@ -3556,24 +3578,8 @@ sub TabChanged
{ {
# TODO: First check if there are some runs given, otherwise disbale # TODO: First check if there are some runs given, otherwise disbale
# TODO: Check if the MSR file exists and decide whether to use it or not
my %All=CreateAllInput(); my %All=CreateAllInput();
my $SlectedTab = musrfit_tabs->currentPageIndex;
# Check if the option for checking for existing files is selected
my $FileExistCheck= FileExistCheck->isOn();
my $FILENAME=$All{"FILENAME"}.".msr";
if ($All{"RunNumbers"} ne "" && $SlectedTab==4 && $FileExistCheck==1) {
if (-e $FILENAME) {
# Warning: MSR file exists
my $Warning = "Warning: MSR file $FILENAME Already exists!\nIf you continue it will overwriten.";
my $WarningWindow = Qt::MessageBox::information( this, "Warning",$Warning);
# my $Answer= Qt::MessageBox::warning( this, "Warning",$Warning, "&No", "&Yes", undef, 1,1);
# $Answer =1,0 for yes and no
# print "Answer=$Answer\n";
}
}
# First make sure we have sharing initialized # First make sure we have sharing initialized
ActivateShComp(); ActivateShComp();
InitializeTab(); InitializeTab();
@ -3588,14 +3594,14 @@ sub GoFit
my %All=CreateAllInput(); my %All=CreateAllInput();
musrfit_tabs->setCurrentPage(1); musrfit_tabs->setCurrentPage(1);
CallMSRCreate(); my $Answer=CallMSRCreate();
if ($Answer) {
my $FILENAME=$All{"FILENAME"}.".msr"; my $FILENAME=$All{"FILENAME"}.".msr";
if (-e $FILENAME) { if (-e $FILENAME) {
my $cmd="musrfit -t $FILENAME"; my $cmd="musrfit -t $FILENAME";
my $pid = open(FTO,"$cmd 2>&1 |"); my $pid = open(FTO,"$cmd 2>&1 |");
while (<FTO>) { while (<FTO>) {
FitTextOutput->append("$_"); FitTextOutput->append("$_");
# print "line= ".$_;
} }
close(FTO); close(FTO);
$cmd="musrview $FILENAME &"; $cmd="musrview $FILENAME &";
@ -3606,6 +3612,8 @@ sub GoFit
FitTextOutput->append("-----------------------------------------------------------------------------------------------------------------------------"); FitTextOutput->append("-----------------------------------------------------------------------------------------------------------------------------");
# update MSR File tab and initialization table # update MSR File tab and initialization table
UpdateMSRFileInitTable(); UpdateMSRFileInitTable();
}
return; return;
} }
@ -3614,8 +3622,10 @@ sub GoPlot
{ {
my %All=CreateAllInput(); my %All=CreateAllInput();
CallMSRCreate(); my $Answer=CallMSRCreate();
my $FILENAME=$All{"FILENAME"}.".msr"; my $FILENAME=$All{"FILENAME"}.".msr";
if ($Answer) {
if (-e $FILENAME) { if (-e $FILENAME) {
my $cmd="musrview $FILENAME &"; my $cmd="musrview $FILENAME &";
my $pid = system($cmd); my $pid = system($cmd);
@ -3623,6 +3633,7 @@ sub GoPlot
FitTextOutput->append("Cannot find MSR file!"); FitTextOutput->append("Cannot find MSR file!");
FitTextOutput->append("-----------------------------------------------------------------------------------------------------------------------------"); FitTextOutput->append("-----------------------------------------------------------------------------------------------------------------------------");
} }
}
return; return;
} }
@ -3633,7 +3644,9 @@ sub ShowMuSRT0
my %All=CreateAllInput(); my %All=CreateAllInput();
musrfit_tabs->setCurrentPage(6); musrfit_tabs->setCurrentPage(6);
# Create MSR file and then run musrt0 # Create MSR file and then run musrt0
CallMSRCreate(); my $Answer=CallMSRCreate();
if ($Answer) {
my $FILENAME=$All{"FILENAME"}.".msr"; my $FILENAME=$All{"FILENAME"}.".msr";
if (-e $FILENAME) { if (-e $FILENAME) {
my $cmd="musrt0 $FILENAME &"; my $cmd="musrt0 $FILENAME &";
@ -3641,6 +3654,7 @@ sub ShowMuSRT0
} else { } else {
print STDERR "Cannot find MSR file!\n"; print STDERR "Cannot find MSR file!\n";
} }
}
return; return;
} }

View File

@ -114,96 +114,6 @@
<property name="title"> <property name="title">
<string>RUN Numbers</string> <string>RUN Numbers</string>
</property> </property>
<widget class="QLineEdit">
<property name="name">
<cstring>RunNumbers</cstring>
</property>
<property name="geometry">
<rect>
<x>15</x>
<y>25</y>
<width>505</width>
<height>26</height>
</rect>
</property>
<property name="sizePolicy">
<sizepolicy>
<hsizetype>0</hsizetype>
<vsizetype>0</vsizetype>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>23</height>
</size>
</property>
<property name="toolTip" stdset="0">
<string>Numbers of RUNs to fit. Multiple runs are comma separated.</string>
</property>
<property name="whatsThis" stdset="0">
<string>Numbers of RUNs to fit. Multiple runs are comma separated.</string>
</property>
</widget>
<widget class="QComboBox">
<item>
<property name="text">
<string>2009</string>
</property>
</item>
<item>
<property name="text">
<string>2008</string>
</property>
</item>
<item>
<property name="text">
<string>2007</string>
</property>
</item>
<item>
<property name="text">
<string>2006</string>
</property>
</item>
<item>
<property name="text">
<string>2005</string>
</property>
</item>
<item>
<property name="text">
<string>2004</string>
</property>
</item>
<property name="name">
<cstring>YEAR</cstring>
</property>
<property name="geometry">
<rect>
<x>420</x>
<y>55</y>
<width>100</width>
<height>26</height>
</rect>
</property>
<property name="sizePolicy">
<sizepolicy>
<hsizetype>0</hsizetype>
<vsizetype>0</vsizetype>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>20</height>
</size>
</property>
</widget>
<widget class="QLabel"> <widget class="QLabel">
<property name="name"> <property name="name">
<cstring>YEARLabel</cstring> <cstring>YEARLabel</cstring>
@ -295,6 +205,96 @@
<string>On beam line</string> <string>On beam line</string>
</property> </property>
</widget> </widget>
<widget class="QComboBox">
<item>
<property name="text">
<string>2009</string>
</property>
</item>
<item>
<property name="text">
<string>2008</string>
</property>
</item>
<item>
<property name="text">
<string>2007</string>
</property>
</item>
<item>
<property name="text">
<string>2006</string>
</property>
</item>
<item>
<property name="text">
<string>2005</string>
</property>
</item>
<item>
<property name="text">
<string>2004</string>
</property>
</item>
<property name="name">
<cstring>YEAR</cstring>
</property>
<property name="geometry">
<rect>
<x>420</x>
<y>55</y>
<width>100</width>
<height>26</height>
</rect>
</property>
<property name="sizePolicy">
<sizepolicy>
<hsizetype>0</hsizetype>
<vsizetype>0</vsizetype>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>20</height>
</size>
</property>
</widget>
<widget class="QLineEdit">
<property name="name">
<cstring>RunNumbers</cstring>
</property>
<property name="geometry">
<rect>
<x>15</x>
<y>25</y>
<width>505</width>
<height>26</height>
</rect>
</property>
<property name="sizePolicy">
<sizepolicy>
<hsizetype>0</hsizetype>
<vsizetype>0</vsizetype>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>23</height>
</size>
</property>
<property name="toolTip" stdset="0">
<string>Numbers of RUNs to fit. Multiple runs are comma separated.</string>
</property>
<property name="whatsThis" stdset="0">
<string>Numbers of RUNs to fit. Multiple runs are comma separated.</string>
</property>
</widget>
</widget> </widget>
<widget class="QGroupBox"> <widget class="QGroupBox">
<property name="name"> <property name="name">
@ -4042,7 +4042,7 @@
<bool>true</bool> <bool>true</bool>
</property> </property>
<property name="on"> <property name="on">
<bool>true</bool> <bool>false</bool>
</property> </property>
<property name="text"> <property name="text">
<string>Change name</string> <string>Change name</string>

View File

@ -212,7 +212,7 @@ void Form1::helpAbout()
void MuSRFitform::CreateAllInput() void MuSRFitform::CreateAllInput()
{ {
# TODO: Need to deliver shared parameters also # TODO: Need to automatically generage years list depending on beamline
my %All=(); my %All=();
# From RUNS Tab # From RUNS Tab
$All{"TITLE"}= TITLE->text; $All{"TITLE"}= TITLE->text;
@ -412,7 +412,27 @@ void MuSRFitform::CallMSRCreate()
{ {
use MSR; use MSR;
my %All=CreateAllInput(); my %All=CreateAllInput();
# Check if the option for checking for existing files is selected
my $FileExistCheck= FileExistCheck->isOn();
my $FILENAME=$All{"FILENAME"}.".msr";
my $Answer=0;
if ($All{"RunNumbers"} ne "" || $All{"RunFiles"} ne "") { if ($All{"RunNumbers"} ne "" || $All{"RunFiles"} ne "") {
if ( $FileExistCheck==1 ) {
if (-e $FILENAME) {
# Warning: MSR file exists
# my $Warning = "Warning: MSR file $FILENAME Already exists!\nIf you continue it will overwriten.";
my $Warning = "Warning: MSR file $FILENAME Already exists!\nDo you want to overwrite it?";
# my $WarningWindow = Qt::MessageBox::information( this, "Warning",$Warning);
# $Answer =1,0 for yes and no
$Answer= Qt::MessageBox::warning( this, "Warning",$Warning, "&No", "&Yes", undef, 1,1);
}
} else {
# Just overwrite file
$Answer=1;
}
if ($Answer) {
if ( $All{"FitAsyType"} eq "Asymmetry" ) { if ( $All{"FitAsyType"} eq "Asymmetry" ) {
my ($Full_T_Block,$Paramcomp_ref)= MSR::CreateMSR(\%All); my ($Full_T_Block,$Paramcomp_ref)= MSR::CreateMSR(\%All);
} }
@ -421,6 +441,8 @@ void MuSRFitform::CallMSRCreate()
} }
UpdateMSRFileInitTable(); UpdateMSRFileInitTable();
} }
}
return $Answer;
} }
void MuSRFitform::UpdateMSRFileInitTable() void MuSRFitform::UpdateMSRFileInitTable()
@ -611,24 +633,8 @@ void MuSRFitform::InitializeTab()
void MuSRFitform::TabChanged() void MuSRFitform::TabChanged()
{ {
# TODO: First check if there are some runs given, otherwise disbale # TODO: First check if there are some runs given, otherwise disbale
# TODO: Check if the MSR file exists and decide whether to use it or not
my %All=CreateAllInput(); my %All=CreateAllInput();
my $SlectedTab = musrfit_tabs->currentPageIndex;
# Check if the option for checking for existing files is selected
my $FileExistCheck= FileExistCheck->isOn();
my $FILENAME=$All{"FILENAME"}.".msr";
if ($All{"RunNumbers"} ne "" && $SlectedTab==4 && $FileExistCheck==1) {
if (-e $FILENAME) {
# Warning: MSR file exists
my $Warning = "Warning: MSR file $FILENAME Already exists!\nIf you continue it will overwriten.";
my $WarningWindow = Qt::MessageBox::information( this, "Warning",$Warning);
# my $Answer= Qt::MessageBox::warning( this, "Warning",$Warning, "&No", "&Yes", undef, 1,1);
# $Answer =1,0 for yes and no
# print "Answer=$Answer\n";
}
}
# First make sure we have sharing initialized # First make sure we have sharing initialized
ActivateShComp(); ActivateShComp();
InitializeTab(); InitializeTab();
@ -642,14 +648,14 @@ void MuSRFitform::GoFit()
{ {
my %All=CreateAllInput(); my %All=CreateAllInput();
musrfit_tabs->setCurrentPage(1); musrfit_tabs->setCurrentPage(1);
CallMSRCreate(); my $Answer=CallMSRCreate();
if ($Answer) {
my $FILENAME=$All{"FILENAME"}.".msr"; my $FILENAME=$All{"FILENAME"}.".msr";
if (-e $FILENAME) { if (-e $FILENAME) {
my $cmd="musrfit -t $FILENAME"; my $cmd="musrfit -t $FILENAME";
my $pid = open(FTO,"$cmd 2>&1 |"); my $pid = open(FTO,"$cmd 2>&1 |");
while (<FTO>) { while (<FTO>) {
FitTextOutput->append("$_"); FitTextOutput->append("$_");
# print "line= ".$_;
} }
close(FTO); close(FTO);
$cmd="musrview $FILENAME &"; $cmd="musrview $FILENAME &";
@ -660,14 +666,18 @@ void MuSRFitform::GoFit()
FitTextOutput->append("-----------------------------------------------------------------------------------------------------------------------------"); FitTextOutput->append("-----------------------------------------------------------------------------------------------------------------------------");
# update MSR File tab and initialization table # update MSR File tab and initialization table
UpdateMSRFileInitTable(); UpdateMSRFileInitTable();
}
return; return;
} }
void MuSRFitform::GoPlot() void MuSRFitform::GoPlot()
{ {
my %All=CreateAllInput(); my %All=CreateAllInput();
CallMSRCreate(); my $Answer=CallMSRCreate();
my $FILENAME=$All{"FILENAME"}.".msr"; my $FILENAME=$All{"FILENAME"}.".msr";
if ($Answer) {
if (-e $FILENAME) { if (-e $FILENAME) {
my $cmd="musrview $FILENAME &"; my $cmd="musrview $FILENAME &";
my $pid = system($cmd); my $pid = system($cmd);
@ -675,6 +685,7 @@ void MuSRFitform::GoPlot()
FitTextOutput->append("Cannot find MSR file!"); FitTextOutput->append("Cannot find MSR file!");
FitTextOutput->append("-----------------------------------------------------------------------------------------------------------------------------"); FitTextOutput->append("-----------------------------------------------------------------------------------------------------------------------------");
} }
}
return; return;
} }
@ -684,7 +695,9 @@ void MuSRFitform::ShowMuSRT0()
my %All=CreateAllInput(); my %All=CreateAllInput();
musrfit_tabs->setCurrentPage(6); musrfit_tabs->setCurrentPage(6);
# Create MSR file and then run musrt0 # Create MSR file and then run musrt0
CallMSRCreate(); my $Answer=CallMSRCreate();
if ($Answer) {
my $FILENAME=$All{"FILENAME"}.".msr"; my $FILENAME=$All{"FILENAME"}.".msr";
if (-e $FILENAME) { if (-e $FILENAME) {
my $cmd="musrt0 $FILENAME &"; my $cmd="musrt0 $FILENAME &";
@ -692,6 +705,7 @@ void MuSRFitform::ShowMuSRT0()
} else { } else {
print STDERR "Cannot find MSR file!\n"; print STDERR "Cannot find MSR file!\n";
} }
}
return; return;
} }