Ignore:
Timestamp:
Apr 11, 2007 12:21:15 PM (15 years ago)
Author:
srkline
Message:
  • Documentation of what parameters are passed to some "Generic" functions. There are only a few of these, like AttenuationFactor?, and they are passed a set parameter list that is always taken from the R/T/I waves that are loaded with the data. If filled properly from the loader, all will work, or the accessor can be fudged to work.
  • A new initialization global was added for beamstop XTol for isTransFile()
  • A new initialization global was added for sample aperture offset (apOff)
File:
1 edited

Legend:

Unmodified
Added
Removed
  • sans/SANSReduction/branches/kline_29MAR07/Put in User Procedures/SANS_Reduction_v5.00/NCNR_DataReadWrite.ipf

    r80 r82  
    12291229// str is the CORRECT length - it will all be written - pad before sending 
    12301230// start is the start byte 
    1231 Function RewriteTextToHeader(fname,str,start) 
     1231Function WriteTextToHeader(fname,str,start) 
    12321232        String fname,str 
    12331233        Variable start 
     
    12461246end 
    12471247 
     1248// sample label, starts at byte 98 
     1249// limit to 60 characters 
    12481250Function WriteSamLabelToHeader(fname,str) 
    12491251        String fname,str 
    12501252         
    1251         RewriteTextToHeader(fname,str,98) 
     1253        if(strlen(str) > 60) 
     1254                str = str[0,59] 
     1255        endif 
     1256        WriteTextToHeader(fname,str,98) 
    12521257        return(0) 
    12531258End 
     
    15841589//associated file suffix is the first 4 characters of a text field starting 
    15851590// at byte 404 
     1591// suffix must be four characters long, if not, it's truncated 
     1592// 
    15861593Function WriteAssocFileSuffixToHeader(fname,suffix) 
    15871594        String fname,suffix 
    1588          
    1589         Variable refnum 
    1590          
    1591         Open/A/T="????TEXT" refnum as fname 
    1592         FSetPos refnum,404 
    1593         FBinWrite refnum, suffix 
    1594         FStatus refnum 
    1595         FSetPos refnum,V_logEOF 
    1596         Close refnum 
    1597          
    1598         return(0) 
    1599 end 
     1595                 
     1596        suffix = suffix[0,3]            //limit to 4 characters 
     1597        WriteTextToHeader(fname,suffix,404) 
     1598         
     1599        return(0) 
     1600end 
Note: See TracChangeset for help on using the changeset viewer.