Changeset 109
- Timestamp:
- May 2, 2007 4:09:28 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sans/SANSReduction/branches/kline_29MAR07/Put in User Procedures/SANS_Reduction_v5.00/ProtocolAsPanel.ipf
r108 r109 1970 1970 //ask user if he wants to use a transmision file for absolute scaling 1971 1971 //or if he wants to enter his own information 1972 DoAlert 1,"<Yes> to enter your own values, <No> to select an empty beam flux file" 1973 If ( (V_Flag==1) ) 1974 //yes selected, prompt for values 1972 err = UseStdOrEmpForABS() 1973 //DoAlert 1,"<Yes> to enter your own values, <No> to select an empty beam flux file" 1974 If ( err==1 ) 1975 //secondary standard selected, prompt for values 1975 1976 Execute "AskForAbsoluteParams()" //missing parameters 1976 1977 else 1977 // noselected, prompt for file, and use this to calculate KAPPA1978 //empty beam flux file selected, prompt for file, and use this to calculate KAPPA 1978 1979 Variable kappa=1 1979 1980 … … 2073 2074 // SRK JUL 2006 don't clear the contents - just kill the window to force new data to be loaded 2074 2075 // - obsucre bug if "ask" in ABS section of protocol clears RAW folder, then Q-axes can't be set from RAW:RealsRead 2075 //ClearDataFolder("RAW") 2076 Endif 2077 Print "Kappa was successfully calculated as = ",kappa 2076 //ClearDataFolder("RAW") 2077 Print "Kappa was successfully calculated as = ",kappa 2078 Endif 2079 2078 2080 End 2079 2081 … … 2125 2127 return(err) 2126 2128 End 2129 2130 Function UseStdOrEmpForABS() 2131 2132 NewPanel/K=2 /W=(139,341,402,448) as "Absolute Scaling" 2133 DoWindow/C junkABSWindow 2134 ModifyPanel cbRGB=(57346,65535,49151) 2135 SetDrawLayer UserBack 2136 SetDrawEnv fstyle= 1 2137 DrawText 21,20,"Method of absolute calibration" 2138 Button button0,pos={52,33},size={150,20},proc=UserSelectABS_Continue,title="Empty Beam Flux" 2139 Button button1,pos={52,65},size={150,20},proc=UserSelectABS_Continue,title="Secondary Standard" 2140 2141 PauseForUser junkABSWindow 2142 NVAR val = root:myGlobals:tmpAbsVal 2143 return(val) 2144 End 2145 2146 //returns 0 if button0 (empty beam flux) 2147 // or 1 if secondary standard 2148 Function UserSelectABS_Continue(ctrlName) :buttonControl 2149 String ctrlName 2150 2151 variable val=0 2152 If(cmpstr(ctrlName,"button0")==0) 2153 val=0 2154 else 2155 val=1 2156 endif 2157 // print "val = ",ctrlName,val 2158 Variable/G root:myGlobals:tmpAbsVal = val 2159 DoWindow/K junkABSWindow //kill panel 2160 return(0) 2161 end 2162 2127 2163 2128 2164 //save the protocol as an IGOR text wave (.itx)
Note: See TracChangeset
for help on using the changeset viewer.