Ignore:
Timestamp:
Sep 10, 2010 5:50:17 PM (12 years ago)
Author:
srkline
Message:

some changes to the XML and the DataSetHandling? to get closer to a functional batch conversion panel. Functionality is mmostly there with these changes. Still to be done is to verify that all of the proper information is being re-written to the converted files.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sans/Dev/trunk/NCNR_User_Procedures/Common/NIST_XML_v40.ipf

    r710 r732  
    565565end 
    566566 
     567// 
     568// !!! nf.Sample_ID is not set correctly here, since it's not read in from the NIST 6-col data file 
     569// and SASprocessnote does not get set either! 
     570// 
    567571Function convertNISTtoNISTXML(fileStr) 
    568572        String fileStr 
     
    639643                         
    640644                endif 
    641                  
    642                 //Tidy up 
    643                 Variable i = 0 
    644                 do 
    645                         WAVE/Z wv= $(StringFromList(i,S_waveNames,";")) 
    646                         if( WaveExists(wv) == 0 ) 
    647                                 break 
    648                         endif 
    649                         KillWaves wv 
    650                         i += 1 
    651                 while (1)       // exit is via break statement 
    652  
    653645         
    654646        endif   //6-col data 
     
    666658 
    667659        writeNISTXML(outfileName, nf) 
     660 
     661        //Tidy up AFTER we're all done, since STRUCT points to wave0,wave1, etc. 
     662        Variable i = 0 
     663        do 
     664                WAVE/Z wv= $(StringFromList(i,S_waveNames,";")) 
     665                if( WaveExists(wv) == 0 ) 
     666                        break 
     667                endif 
     668                KillWaves wv 
     669                i += 1 
     670        while (1)       // exit is via break statement 
    668671 
    669672end 
     
    695698                if (stringmatch(buffer,"*FIRST File LABEL:*") == 1) 
    696699                        NISTfile.title = TrimWS(StringFromList(1,buffer, ":")) 
    697                 elseif(stringmatch(buffer,"*LABEL:*") == 1) 
     700                endif 
     701                if(stringmatch(buffer,"*LABEL:*") == 1) 
    698702                        NISTfile.title = TrimWS(StringFromList(1,buffer, ":")) 
     703                endif 
     704                if(stringmatch(buffer,"NSORT*") == 1) 
     705                        NISTfile.title = buffer 
    699706                endif 
    700707                 
Note: See TracChangeset for help on using the changeset viewer.