var trigchan,ur,sampl,n,ch,v,log%,logfilename$,vh%,pretrig,q,posttrig,s; vh%:=View(); 'get view of data file 'clear log window View(LogHandle()); EditSelectAll(); EditClear(); 'bring data file to front again View(vh%); CursorDelete(-1); CursorNew(); Cursornew(Cursor(1)+1); interact("place Cursors around area that you wish to dump ",1023); n:=Cursor(1); ur:=n; ch:=input("What channel",12); sampl:=input("What sampling distance (ms)",1); sampl:=sampl/1000; trigchan:=input("trigger channel (0 for no channel)?",401); 'prepare Logfile Printlog("norm. Zeit", " ","Zeit"," ","Datenwert", " ", "Triggerpunktnummer", " ", "sampling distance:",sampl*1000," ms"); if trigchan > 0 then pretrig:=input("time to sample before each trigger (ms)?",100); pretrig:=pretrig/1000; posttrig:=input("time to sample after each trigger (ms)?",200); posttrig:=posttrig/1000; endif; q:=0; s:=0; 'get data if trigchan > 0 then q:=nexttime(trigchan,q); n:=q-pretrig; while q