[ver]
	4
[sty]
	
[files]
[charset]
	82
	ANSI (Windows, IBM CP 1252)
[revisions]
	0
[sequence]
	82
	0
	0
	0
	12
	0
	Numbered List
	569
	bullet
	569
	indent bullet
	569
	Note
	569
	indent Note
	569
	tip
	569
	Caution
	569
	indentCaution
	569
	find
	0
	Footnote
	569
	indent Tip
	569
	indent Find
[prn]
	Apple LaserWriter II NTX
[port]
	LPT1:
[lang]
	1
[fldnames]
	Field1
	Field2
	Field3
	Field4
	Field5
	Field6
	Field7
	Field8
[desc]
	File ch06.rtf was converted from Rich Text Format on 4/7/94
	
	
	
	
	802475816
	64
	765729215
	154
	8
	0
	0
	0
	0
	
	
	
	
	
	
	1
[fopts]
	0
	1
	0
	0
	
	
[lnopts]
	2
	Body Text
	1
[docopts]
	5
	2
[GramStyle]
	
[ParaNum]
	1
[tag]
	Body Text
	2
	[fnt]
		Palatino
		200
		0
		49152
	[algn]
		1
		3
		720
		0
		0
	[spc]
		24
		200
		4
		120
		120
		4
		100
	[brk]
		36
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		0
		
		0
		1
		1
		0
		0
		0
		0
	[nfmt]
		280
		1
		2
		.
		,
		$
	1Body Text
	3
	1
	600
	1
	1200
	1
	3720
	0
[tag]
	Ahead
	3
	[fnt]
		Helvetica
		280
		0
		16385
	[algn]
		1
		1
		0
		0
		0
	[spc]
		40
		300
		4
		360
		120
		4
		100
	[brk]
		80
	[line]
		9
		0
		4
		0
		1
		1
		1
		110
		10
		1
	[spec]
		0
		2
		
		0
		1
		1
		0
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	Body Text
	0
	0
[tag]
	Bhead
	4
	[fnt]
		Helvetica
		240
		0
		16385
	[algn]
		1
		3
		0
		0
		0
	[spc]
		40
		280
		4
		100
		90
		4
		100
	[brk]
		80
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		2
		
		0
		1
		1
		0
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	Body Text
	0
	0
[tag]
	Chead
	5
	[fnt]
		Helvetica
		200
		0
		16385
	[algn]
		1
		3
		720
		0
		0
	[spc]
		40
		240
		4
		80
		0
		4
		100
	[brk]
		80
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		2
		
		0
		1
		1
		0
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	Body Text
	0
	0
[tag]
	Numbered List
	6
	[fnt]
		Palatino
		200
		0
		49152
	[algn]
		1
		3
		744
		336
		336
	[spc]
		40
		240
		4
		0
		80
		4
		100
	[brk]
		0
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		3
		<*:>.
		0
		3
		1
		1
		2
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	Numbered List
	0
	0
[tag]
	bullet
	7
	[fnt]
		Palatino
		200
		0
		49152
	[algn]
		1
		3
		720
		300
		300
	[spc]
		40
		240
		4
		80
		80
		4
		100
	[brk]
		0
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		4
		<*1>
		0
		3
		1
		1
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	bulleted list
	0
	0
[tag]
	1st lev para
	8
	[fnt]
		Palatino
		200
		0
		49152
	[algn]
		1
		3
		1080
		0
		0
	[spc]
		40
		240
		4
		0
		80
		4
		100
	[brk]
		4
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		4
		
		0
		1
		1
		1
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	1st lev para
	0
	0
[tag]
	mono
	9
	[fnt]
		Courier
		180
		0
		32769
	[algn]
		1
		3
		720
		0
		0
	[spc]
		24
		220
		4
		120
		120
		4
		100
	[brk]
		36
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		4
		
		0
		1
		1
		0
		0
		0
		0
	[nfmt]
		280
		1
		2
		.
		,
		$
	mono
	22
	1
	864
	1
	1209
	1
	1555
	1
	1900
	1
	2246
	1
	2592
	1
	2937
	1
	3283
	1
	3628
	1
	3974
	1
	4320
	1
	4665
	1
	5011
	1
	5356
	1
	5702
	1
	6048
	1
	6393
	1
	6739
	1
	7084
	1
	7430
	1
	7776
	1
	8121
	0
[tag]
	indent bullet
	11
	[fnt]
		Palatino
		200
		0
		49152
	[algn]
		1
		3
		1104
		216
		216
	[spc]
		40
		240
		4
		0
		80
		4
		100
	[brk]
		0
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		4
		<*1>
		0
		3
		1
		1
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	indent bullet
	0
	0
[tag]
	Note
	12
	[fnt]
		Helvetica
		200
		0
		16384
	[algn]
		1
		3
		720
		600
		0
	[spc]
		40
		240
		4
		0
		80
		4
		100
	[brk]
		0
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		4
		Note
		0
		3
		1
		1
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	Note
	0
	0
[tag]
	2nd lev para
	0
	[fnt]
		Palatino
		200
		0
		49152
	[algn]
		1
		3
		1320
		0
		0
	[spc]
		40
		240
		4
		0
		80
		4
		100
	[brk]
		4
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		4
		
		0
		1
		1
		1
		2
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	2nd lev para
	0
	0
[tag]
	Table Text
	0
	[fnt]
		Palatino
		180
		0
		49152
	[algn]
		1
		1
		0
		0
		0
	[spc]
		40
		200
		4
		79
		0
		3
		100
	[brk]
		4
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		0
		
		0
		1
		1
		0
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	Table Text
	0
	0
[tag]
	Body Text1
	0
	[fnt]
		Palatino
		200
		0
		49152
	[algn]
		1
		3
		720
		0
		0
	[spc]
		40
		240
		4
		20
		40
		4
		100
	[brk]
		36
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		1
		
		18944
		1
		1
		0
		2
		0
		0
	[nfmt]
		280
		1
		2
		.
		,
		$
	Body Text1
	4
	1
	2390
	1
	2869
	1
	3347
	1
	3826
	0
[tag]
	indent Note
	0
	[fnt]
		Helvetica
		200
		0
		16384
	[algn]
		1
		3
		1080
		600
		0
	[spc]
		40
		240
		4
		0
		80
		4
		100
	[brk]
		0
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		4
		Note
		0
		3
		1
		1
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	indent Note
	0
	0
[tag]
	tip
	0
	[fnt]
		Helvetica
		200
		0
		16384
	[algn]
		1
		3
		720
		480
		0
	[spc]
		40
		240
		4
		0
		80
		4
		100
	[brk]
		4
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		4
		Tip
		0
		3
		1
		1
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	tip
	0
	0
[tag]
	Caution
	0
	[fnt]
		Helvetica
		200
		0
		16384
	[algn]
		1
		3
		720
		900
		0
	[spc]
		40
		240
		4
		0
		80
		4
		100
	[brk]
		4
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		4
		Caution
		0
		3
		1
		1
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	Caution
	0
	0
[tag]
	indentCaution
	0
	[fnt]
		Helvetica
		200
		0
		16384
	[algn]
		1
		3
		1080
		900
		0
	[spc]
		40
		240
		4
		0
		80
		4
		100
	[brk]
		4
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		4
		Caution
		0
		3
		1
		1
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	indentCaution
	0
	0
[tag]
	Term
	0
	[fnt]
		Palatino
		200
		0
		49153
	[algn]
		1
		3
		720
		0
		0
	[spc]
		24
		240
		4
		0
		0
		4
		100
	[brk]
		80
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		2
		
		0
		1
		1
		0
		0
		0
		0
	[nfmt]
		280
		1
		2
		.
		,
		$
	Body Text
	0
	0
[tag]
	indent Term
	0
	[fnt]
		Palatino
		200
		0
		49153
	[algn]
		1
		3
		1080
		0
		0
	[spc]
		24
		240
		4
		0
		0
		4
		100
	[brk]
		16
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		2
		
		0
		1
		1
		0
		0
		0
		0
	[nfmt]
		280
		1
		2
		.
		,
		$
	indent Term
	0
	0
[tag]
	find
	0
	[fnt]
		Helvetica
		200
		0
		16384
	[algn]
		1
		3
		720
		1800
		0
	[spc]
		40
		240
		4
		0
		80
		4
		100
	[brk]
		4
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		4
		Finding Out More
		0
		3
		1
		1
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	find
	0
	0
[tag]
	procdure Bhd
	0
	[fnt]
		Helvetica
		220
		0
		16385
	[algn]
		1
		3
		0
		0
		0
	[spc]
		40
		260
		4
		100
		90
		4
		100
	[brk]
		80
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		2
		
		0
		1
		1
		0
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	Numbered List
	0
	0
[tag]
	procdure Chd
	0
	[fnt]
		Helvetica
		200
		0
		16385
	[algn]
		1
		3
		720
		0
		0
	[spc]
		40
		240
		4
		80
		80
		4
		100
	[brk]
		80
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		2
		
		0
		1
		1
		0
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	Numbered List
	0
	0
[tag]
	formula
	0
	[fnt]
		Helvetica
		180
		0
		16384
	[algn]
		1
		3
		1080
		0
		0
	[spc]
		40
		220
		4
		0
		80
		4
		100
	[brk]
		4
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		4
		
		0
		1
		1
		1
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	formula
	0
	0
[tag]
	Table Title
	0
	[fnt]
		Helvetica
		180
		0
		16385
	[algn]
		1
		3
		720
		0
		0
	[spc]
		40
		220
		4
		40
		80
		4
		100
	[brk]
		16
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		4
		
		0
		1
		1
		0
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	Table Title
	0
	0
[tag]
	Column Head
	0
	[fnt]
		Palatino
		180
		0
		49154
	[algn]
		1
		3
		0
		0
		0
	[spc]
		40
		220
		4
		0
		0
		3
		100
	[brk]
		4
	[line]
		11
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		4
		
		0
		1
		1
		0
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	Column Head
	0
	0
[tag]
	call-out
	0
	[fnt]
		Helvetica
		160
		0
		16384
	[algn]
		1
		3
		0
		0
		0
	[spc]
		40
		180
		4
		0
		0
		1
		100
	[brk]
		0
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		4
		
		0
		1
		1
		0
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	call-out
	0
	0
[tag]
	chap number
	0
	[fnt]
		Helvetica
		720
		0
		16385
	[algn]
		1
		3
		0
		0
		0
	[spc]
		40
		520
		4
		0
		0
		4
		100
	[brk]
		0
	[line]
		17
		1680
		4
		0
		1
		1
		1
		420
		10
		1
	[spec]
		0
		2
		
		0
		1
		1
		0
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	chap number
	0
	0
[tag]
	Chapter Title
	0
	[fnt]
		Helvetica
		320
		0
		16385
	[algn]
		1
		3
		720
		0
		0
	[spc]
		40
		360
		4
		0
		480
		3
		100
	[brk]
		81
	[line]
		17
		8520
		3
		0
		1
		3
		1
		644
		10
		1
	[spec]
		0
		2
		
		0
		1
		1
		0
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	Body Text
	0
	0
[tag]
	1st Pg Footer
	0
	[fnt]
		Palatino
		180
		0
		49153
	[algn]
		2
		3
		0
		0
		0
	[spc]
		33
		273
		1
		0
		0
		1
		100
	[brk]
		0
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		4
		
		0
		1
		1
		0
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	1st Pg Footer
	0
	0
[tag]
	right footer
	0
	[fnt]
		Palatino
		180
		0
		49153
	[algn]
		4
		1
		0
		0
		0
	[spc]
		33
		216
		1
		60
		0
		3
		100
	[brk]
		32
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		4
		
		0
		1
		1
		0
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	right footer
	1
	3
	8640
	0
[tag]
	left footer
	0
	[fnt]
		Palatino
		180
		0
		49153
	[algn]
		4
		1
		0
		0
		5212
	[spc]
		33
		216
		1
		60
		0
		3
		100
	[brk]
		32
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		4
		
		0
		1
		1
		0
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	left footer
	1
	3
	8640
	0
[tag]
	Footnote
	0
	[fnt]
		Times New Roman
		180
		0
		49152
	[algn]
		1
		3
		0
		244
		0
	[spc]
		40
		2400
		3
		0
		0
		1
		100
	[brk]
		4
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		0
		<*:>
		0
		1
		1
		256
		0
		0
		0
	[nfmt]
		280
		1
		2
		.
		,
		$
	Footnote
	0
	0
[tag]
	Figure Title
	0
	[fnt]
		Helvetica
		180
		0
		16385
	[algn]
		1
		3
		720
		0
		0
	[spc]
		40
		220
		4
		40
		80
		4
		100
	[brk]
		80
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		4
		
		0
		1
		1
		0
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	Body Text
	0
	0
[tag]
	indent Tip
	0
	[fnt]
		Helvetica
		200
		0
		16384
	[algn]
		1
		3
		1080
		480
		0
	[spc]
		40
		240
		4
		0
		80
		4
		100
	[brk]
		4
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		4
		Tip
		18944
		3
		1
		1
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	indent tip
	0
	0
[tag]
	indent Find
	0
	[fnt]
		Helvetica
		200
		0
		16384
	[algn]
		1
		3
		1080
		1800
		0
	[spc]
		40
		240
		4
		0
		80
		4
		100
	[brk]
		4
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		4
		Finding Out More
		18944
		3
		1
		1
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	indent find
	0
	0
[tag]
	copyrt
	0
	[fnt]
		Palatino
		180
		0
		49152
	[algn]
		1
		3
		0
		0
		0
	[spc]
		24
		220
		4
		0
		60
		4
		100
	[brk]
		36
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		1
		
		18944
		1
		1
		0
		2
		0
		0
	[nfmt]
		280
		1
		2
		.
		,
		$
	copyrt
	4
	1
	2390
	1
	2869
	1
	3347
	1
	3826
	1200
[tag]
	seealso
	0
	[fnt]
		Helvetica
		200
		0
		16385
	[algn]
		1
		3
		720
		0
		0
	[spc]
		40
		240
		4
		80
		0
		4
		100
	[brk]
		16
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		2
		
		0
		1
		1
		0
		0
		0
		0
	[nfmt]
		272
		1
		2
		.
		,
		$
	seealso
	0
	0
[tag]
	crossref
	0
	[fnt]
		Palatino
		200
		0
		49152
	[algn]
		1
		3
		720
		0
		0
	[spc]
		40
		240
		4
		0
		0
		4
		100
	[brk]
		36
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		1
		
		18944
		1
		1
		0
		2
		0
		0
	[nfmt]
		280
		1
		2
		.
		,
		$
	crossref
	4
	1
	2390
	1
	2869
	1
	3347
	1
	3826
	0
[tag]
	popref
	0
	[fnt]
		Palatino
		200
		0
		49152
	[algn]
		513
		3
		720
		0
		720
	[spc]
		40
		240
		4
		0
		0
		4
		100
	[brk]
		36
	[line]
		8
		0
		1
		0
		1
		1
		1
		10
		10
		1
	[spec]
		0
		1
		
		18944
		1
		1
		0
		2
		0
		0
	[nfmt]
		280
		1
		2
		.
		,
		$
	popref
	4
	1
	2390
	1
	2869
	1
	3347
	1
	3826
	0
[frm]
	1
	1572932
	2181
	4404
	8224
	7031
	0
	3
	1
	1 0 0 0 0 0 0
	0
	16777215
	5
	0
	0
	720 19968
	[frmlay]
		5204
		6043
		3
		0
		0
		3
		4404
		0
		0
		2
		0
		1
		1
		0
		1
		960
		5280
		0
	[tbl]
		 4 2 200 86 1440 0 5 43 43
		[h]
			 0 240 86 18 0 2 0
			 1 1000 86 2 0 1 0
			 2 400 86 2 0 1 0
			 3 600 86 2 0 1 0
		[e]
		[w]
			 0 1320 120 6 0
			 1 4560 0 2 0
		[e]
		[data]
			 0 0 0 0 0 0 0 1 0 0 0 0
@Column Head@File type

>
			 0 1 0 0 0 0 0 1 0 0 0 0
@Column Head@Description

>
			 1 0 0 0 0 0 0 1 0 0 0 0
<:f>Sequential

>
			 1 1 0 0 0 0 0 1 0 0 0 0
The simplest and most common. It is the equivalent of a common text file. Data in sequential files is delimited with the platform's end-of-line indicator (carriage return, line feed, or both) and is easily read with a text editor. 

>
			 2 0 0 0 0 0 0 1 0 0 0 0
<:f>Random

>
			 2 1 0 0 0 0 0 1 0 0 0 0
The most useful for structured data. It is not readable except through LotusScript programs.

>
			 3 0 0 0 0 0 0 1 0 0 0 0
<:f>Binary

>
			 3 1 0 0 0 0 0 1 0 0 0 0
The most complex. It requires detailed programming to manipulate, because access is defined at the level of bytes on the disk.

>
		[e]
	[tble]
[lay]
	Standard
	3079
	[rght]
		12960
		10166
		1
		960
		1200
		3
		960
		720
		0
		1
		0
		1
		0
		2
		1
		960
		9446
		5
		1
		720
		1
		1440
		1
		2880
		1
		4320
		1
		5760
	[lft]
		12960
		10166
		1
		720
		1200
		3
		960
		960
		0
		1
		0
		1
		0
		2
		1
		720
		9206
		5
		1
		720
		1
		1440
		1
		2880
		1
		4320
		1
		5760
	[hlft]
	[lyfrm]
		1
		3008
		0
		0
		10166
		960
		0
		1
		3
		1 0 0 0 0 0 0
		0
		0
		1
	[frmlay]
		960
		10166
		1
		720
		180
		3
		480
		960
		0
		1
		0
		1
		1
		0
		1
		720
		9206
		0
	[txt]
@right footer@LotusScript Language Reference	10/03/94

>
	[hrght]
	[lyfrm]
		1
		11200
		0
		0
		10166
		960
		0
		1
		3
		1 0 0 0 0 0 0
		0
		0
		2
	[frmlay]
		960
		10166
		1
		960
		180
		3
		480
		720
		0
		1
		0
		1
		1
		0
		1
		960
		9446
		0
	[txt]
@right footer@10/03/94<:f>	LotusScript Language Reference

>
	[flft]
	[lyfrm]
		1
		5056
		0
		11760
		10166
		12960
		0
		1
		3
		1 0 0 0 0 0 0
		0
		0
		3
	[frmlay]
		12960
		10166
		1
		720
		480
		3
		11940
		960
		0
		1
		0
		1
		1
		0
		1
		720
		9206
		0
	[txt]
@right footer@page <:P10,0,>	Lotus Strictly Private

>
	[frght]
	[lyfrm]
		1
		13248
		0
		11760
		10166
		12960
		0
		1
		3
		1 0 0 0 0 0 0
		0
		0
		4
	[frmlay]
		12960
		10166
		1
		960
		480
		3
		11940
		720
		0
		1
		0
		1
		1
		0
		1
		960
		9446
		0
	[txt]
@right footer@Lotus Strictly Private	page <:P10,0,>

>
[elay]
[l1]
	0
[pg]
	6
	7 0 36 512 0 0 0 240 65535 Standard	65535 0 0	0 0 0 0 0 0 0 65535 0 0 65535 0 0 0 0 0
	21 93 40 0 1 0 0 220 65535 Standard	65535 0 0	0 0 0 0 0 0 0 65535 0 0 65535 0 0 0 0 0
	36 19 67 32 1 0 0 220 65535 Standard	65535 0 0	0 0 0 0 0 0 0 65535 0 0 65535 0 0 0 0 0
	50 111 51 0 1 1 0 220 65535 Standard	65535 0 0	0 0 0 0 0 0 0 65535 0 0 65535 0 0 0 0 0
	56 0 89 512 0 0 0 200 65535 Standard	65535 0 0	0 0 0 0 0 0 0 65535 0 0 65535 0 0 0 0 0
	64 354 14 512 0 0 0 200 65535 Standard	65535 0 0	0 0 0 0 0 0 0 65535 0 0 65535 0 0 0 0 0
[edoc]
@Chapter Title@<:#1364,8486><:f>Chapter 6  <**>File Operations

<:#600,8486><:f>This section describes the attributes of each type of file in LotusScript, and discusses the statements and functions that manipulate them. For specific details on each statement and function, see Chapter 11, 
</S>Functions and Statements.</T>

<:#400,8486><:f>The following table shows the three kinds of files in LotusScript: sequential, random, and binary. 

<:t0>

<:#1000,8486><:f><:f><:f>To use a file to store and manipulate data, it must be opened first. When a file is opened in LotusScript, it is associated with a file number, an integer between 1 and 255. This number is used in most input and output operations to indicate whi
ch file is being manipulated. (A few file operations use the file name instead of a number.) The association remains until the script is finished using the file, when it is closed.

@Chead@<:#240,8486><:f>Related topics

@popref@<:f><:f>Limits on File Operations<:p<* >>

@Ahead@<:#410,8486>Sequential Files<:X8,2;Index "File operations" # "sequential files"><:X8,2;Index "Files" # "sequential"><:X8,2;Index "Sequential files" #>

<:#1000,8486><:f>Sequential files are ordinary text files. Each character in the file is assumed to be either a text character or some other ASCII control character such as newline. Sequential files provide access at the level of lines or strings of text: that is, data 
that is <+">not<-"> divided into a series of records. However, sequential files are not well suited for numbers, because numbers are written as character strings.

@Bhead@<:#280,8486><:f><:f>Opening Sequential Files<:X8,2;Index "Files" # "opening, sequential"><:X8,2;Index "Sequential files" # "opening"><:X8,2;Index "Opening files" # "sequential">

@1st Paragraph@<:#600,8486><:f>A sequential file can be opened in one of three modes: Input, Output, or Append. After opening a file, you must close it before opening it in another mode. Use the Open statement with the following syntax to open a sequential file:

<:#200,8486><:f><:f><:f><+!>Open <-!><+">file_name<-"> <[><+!>For <-!>{<+!>Input 
<-!>| <+!>Output <-!>| <+!>Append<-!>} ] <+!>As<+"> <-!>file_number<-"> <[><+!>Len =<-!> 
<+">buffer_size<-">]

<:#600,8486>Sequential Input mode signifies read-only access to the file, while Output signifies write-only. Append means write-only, but starting at the end of the file. Access in all three sequential modes is one line at a time.

<:#800,8486><:f>The <+">buffer_size <-">supplied to the Open statement is the number of characters to be loaded into the internal buffer before being flushed to disk. This is a performance-enhancing feature: the larger the buffer, the faster the I/O. However, larger bu
ffer sizes require more memory. The default buffer size for sequential files is 512 bytes.

<:#600,8486><:f>When you try to open a file for sequential input, the file must already exist. If it doesn</R>t, an error is generated. When you try to open a nonexistent file for output or append mode, the file is created automatically.

@Bhead@<:#280,8486><:f>Writing to Sequential Files<:X8,2;Index "Files" # "writing, sequential"><:X8,2;Index "Sequential files" # "writing"><:X8,2;Index "Writing to files" # "sequential">

@1st Paragraph@<:#400,8486><:f>To write the contents of variables to a sequential file (opened in output or append mode), use the Print # statement. For example:

@mono@<:#220,8486>PRINT<+!> <-!>#myfile,Var1,Var2

<:#600,8486><:f>This writes the contents of Var1 and Var2 (separated by tabs, because of the commas in the statement) to the file numbered myfile. The parameters to Print can be strings or numeric expressions; they are converted to their string representations automati
cally.

<:#600,8486>The Write # statement also can write output to files. It generates output compatible with the Input # statement by separating each pair of expressions with a comma, and puts quotation marks around strings. For example, the commands

@mono@<:#660,8486>DIM<++> V<-+>ar1 AS VARIANT<++>: V<-+>ar<++>1 = 456<**><-+>DIM Var<++>2 
<-+>AS VARIANT: Var2 = NULL<++>           <**><-+>WRITE #myfile,"Testing",123,Var1,Var2

<:#200,8486><:f>generate the following line in the file numbered myfile:

@mono@<:#220,8486>"Testing",123,456,#NULL#

@Bhead@<:#280,8486><:f>Reading from Sequential Files<:X8,3;Index "Files" # "reading, sequential"><:X8,3;Index "Sequential files" # "reading"><:X8,3;Index "Reading from files" # "sequential">

@1st Paragraph@<:#400,8486><:f>To read data from a sequential file, open the file for Input mode. Then use Line Input #, Input, or Input #  to read data from the file into variables.

<:#400,8486>Line Input # reads one line of text from a file, up to an end-of-line. The end-of-line is not returned in the string. For example:

@mono@<:#880,8486>DO UNTIL EOF(myfile)<**>  LINE INPUT #myfile, nextline<**>  PRINT<++> 
<-+>nextline<**>LOOP

<:#400,8486><:f>reads a file one line at a time until end-of-file. The Print statement displays the line and appends an EOL sequence.

<:#400,8486>The Input # statement can be used to read in data that was formatted and written with the Write # statement. For example, if the file numbered myfile contained the line:

@mono@<:#220,8486>"Testing",123,456,#NULL#

<:#400,8486><:f>then the following statements would read </S>Testing</T> into str, 123 into int1, 456 into int2,<:f,2Palatino,> 
<:f>and the value NULL into var1:

@mono@<:#440,8486>DIM str<++> <-+>AS STRING, int1 AS INTEGER, int2 AS INTEGER, var1 AS VARIANT<**>INPUT #myfile, str, int1, int2, var1

<:#600,8486><:f>If you find that you are using Write # and Input # with sequential files often, you should consider using a random file instead. Random files are better suited for record-oriented data, as illustrated in the next section.

<:#600,8486><:f>You can also use the Input function to read data from a sequential file. This function takes the number of characters to read as an argument, and returns it to the caller. Input$ returns a string to the caller, Input returns a Variant variable.

<:#200,8486><:f>For example, this example reads an entire file at once into a string variable:

@mono@<:#440,8486>DIM Lines AS STRING<**>Lines = INPUT$(LOF(myfile), myfile)  'LOF returns "length of file"

@Ahead@<:#410,8486><:f>Random Files<:X8,4;Index "File operations" # "random files"><:X8,4;Index "Files" # "random"><:X8,4;Index "Random files" #>

<:#800,8486><:f>A random file is made up of a series of records of identical length. A record can correspond to a built-in data type, such as Integer or String, or a user-defined type, in which each  record is broken down into fields corresponding to the members of the
 type.

<:#600,8486>Random access is the default mode for opening files. Thus, if you don</R>t supply Binary or one of the sequential keywords (Input, Output, or Append), random access is assumed.

@Bhead@<:#280,8486><:f><:f>Opening Random Files<:X8,4;Index "Files" # "opening, random"><:X8,4;Index "Random files" # "opening"><:X8,4;Index "Opening files" # "random">

@1st Paragraph@<:#200,8486><:f>To open a file for random access, use the following syntax for the Open statement:

<:#200,8486><:f><+!>Open <-!><+">file_name<-"> <+!>For Random As<-!> <+">file_number<-"> <[><+!>Len = 
<-!><+">record_length<-">]

<:#400,8486><:f>where <+">record_length<-"> is the length of each record in the file. The default length is 128 bytes.

<:#200,8486>If the file does not exist, it is created.

@Bhead@<:#280,8486><:f>Defining Record Types<:X8,4;Index "Random files" # "defining record types">

@1st Paragraph@<:#800,8486><:f>Random files are organized by records, each with the same length, containing one or more fields. A record with one field corresponds to any built-in data type, such as Integer or String. A record with more than one field corresponds to a user-defined ty
pe.

<:#1000,8486><:f>Because records in a random file must all have the same length, strings in types should be fixed-length. Otherwise, data read from the file can be incorrect. If a string copied into a file record contains fewer characters than the record</R>s fixed leng
th, the remainder of the record is left unchanged. If a string is too long for a record, it is truncated when written.

<:#1400,8486><:f,,0,0,0>For simplicity, string fields inside the user-defined type should be fixed-length. If you do use variable-length strings in your type, you must be sure tha<:f>t the Len part of the Open statement specifies a length that is large enough to hold th
e longest strings you wish to write to the file. Also, the Len function will not be able to give you a reliable value for the length of the record. (You will need to estimate that.)  You will also be unable to navigate between records by omitting the record
 number in the Get and Put s<:f,,0,0,0>tatements.<:f>

<:#200,8486><:f>User-defined types can be used to define compound records. For example:

@mono@<:#1540,8486>TYPE MyRecord<**>  <++>I<-+>d<++> <-+>AS INTEGER				'Integers are 2 bytes long<**>  Salary AS CURRENCY			'Currency is 8 bytes<**>  HireDate AS DOUBLE      
	'Dates are also 8 bytes<**>  LastName <++>AS <-+>STRING * 15	'Fixed-length string of 30 bytes<**>  FirstName 
<++>as <-+>STRING<++> <-+>* 15	'Fixed-length string of 30 bytes<**>END TYPE

<:#400,8486>This record is 78 bytes long, so supply Len = 78 in the Open statement. The length of a type can be determined at runtime using the Len function. For example:

@mono@<:#1320,8486>RecLen AS INTEGER<**>MyFile AS INTEGER<**>Rec AS MyRecord<**>MyFile = 1					'The file number we'll use for this file<**>RecLen = LEN(rec)			'The record length for this file<**>OPEN "myfile.txt" FOR RANDOM AS MyFile LEN = RecLen

@Bhead@<:#280,8486>Reading from Random Files<:X8,5;Index "Files" # "reading, random"><:X8,5;Index "Random files" # "reading"><:X8,5;Index "Reading from files" # "random">

@1st Paragraph@<:#400,8486><:f>Use the Get statement to read from a random file into variables. This example reads from the file numbered myfile, at record number 5, into the variable myrec:

@mono@<:R1,4,1,1200,1,1680,1,2160,1,3450,><:#880,8486>Position AS INTEGER     ' The record number to retrieve from the file<**>Position = 5            ' I want to read the fifth record<**>MyRec AS MyRecord       ' The variable to read into<**>GET MyFile, Position, MyRec

<:R><:f>For the details of the Get statement, see Chapter 11, </S>Functions and Statements.</T><:p<* >>

@Bhead@<:#280,8486><:f>Writing to Random Files<:X8,6;Index "Files" # "writing, random"><:X8,6;Index "Random files" # "writing"><:X8,6;Index "Writing to files" # "random">

@1st Paragraph@<:#400,8486><:f>Use the Put statement to write to a random file. You can use Put to add new records to a random file, or to replace records in a random file.

<:#600,8486>Put takes three parameters: the file number to access, the record number to access, and a variable containing the data you wish to write. To replace a record in a random file, simply supply its record number:

@mono@<:#660,8486>Pos AS INTEGER<**>Pos = 5<**>PUT<++> M<-+>yFile, Pos, MyRec  ' Replace record 5 with the contents of MyRec

<:#600,8486><:f>To add new records to a random file, use a record number equal to one more than the number of records in the file. To add a record to a file that contains 5 records, for example, use a position of 6.

<:#400,8486><:f>To delete a record from a random file, you can move each record following it 
</S>down</T> a position, thus overwriting the record you wish to delete. For example:

@mono@<:#1320,8486>MyRec AS MyRecord<**>TempRec AS MyRecord<**>FOR<++> I<-+> = Position TO<++> 
<-+>LastRecord -1<**>  GET MyFile, I+1, TempRec<**>  PUT MyFile, I, TempRec<**>NEXT<++> 
<-+>I

<:f>The problem with this technique is that it leaves a duplicate record at the end of the file. A better approach is to create a new file and copy all the valid records from the original file into the new file. Close the original file and then use the Kill
 statement to delete it, then use the Name command to rename the new file to the same name as the original.<:p<* >>

@Ahead@<:#410,8486><:f>Binary Files<:X8,7;Index "File operations" # "binary files"><:X8,7;Index "Files" # "binary"><:X8,7;Index "Binary files" #>

<:#800,8486><:f>Binary files are designed to provide the ultimate in control over how your data is organized for both reading and writing. The drawback is that you must know exactly how the file was written in order to read it properly. While binary access has the fewe
st functions and subs to manipulate data, it is also the most flexible.

@Bhead@<:#280,8486><:f><:f>Opening Binary Files<:X8,7;Index "Files" # "opening, binary"><:X8,7;Index "Binary files" # "opening"><:X8,7;Index "Opening files" # "binary">

@1st Paragraph@<:#200,8486><:f>To open a binary file, use the following syntax:

<:#200,8486><:f><+!>Open <-!><+">file_name<-"> <+!>For Binary As<-!> <+">file_number<-">

<:#200,8486><:f>If you include a record-length argument, it is ignored.

<:#400,8486><:f>If the file does not exist, it is created, regardless of the access type supplied to the Open statement. See Chapter 11, 
</S>Functions and Statements,</T> for details.

@Bhead@<:#280,8486><:f>Using Variable-Length Fields<:X8,7;Index "File operations" # "binary files"><:X8,7;Index "Binary files" # "variable-length records">

@1st Paragraph@<:#1200,8486><:f>Unlike random files, binary files can hold variable-length records. Thus, strings do not have to be fixed-length. However, you need to know the sizes of strings in order to read them. It is good programming practice to assign a length field to each vari
able-length record (each string) for this purpose. However, this is not necessary if the string is a component of a user-defined type. In this case, LotusScript automatically assigns a length field in the file to each variable-length string.

<:#400,8486><:f>Binary access provides a byte-by-byte view of a file. A file appears to be a continuous stream of bytes, which may or may not be alphanumeric characters.

@Bhead@<:#280,8486><:f>Writing to Binary Files<:X8,7;Index "Files" # "writing, binary"><:X8,7;Index "Binary files" # "writing"><:X8,7;Index "Writing to files" # "binary">

@1st Paragraph@<:#200,8486><:f>To write to a binary file, use the Put statement, which has the following syntax:

<:#200,8486><:f><+!>Put<-!> <+">file_number<-"><+!>,<-!> <+">byte_position<-"><+!>,<-!> 
<+">variable_name<-">

<:#600,8486><:f>The <+">byte_position <-">parameter is the position in the file at which to start writing. The first byte in a file is at position 1; position zero is illegal, and specifying it results in a 
</S>Bad record number</T> error. For details, see Chapter 11, </S>Functions and Statements.</T>     

@Bhead@<:#280,8486><:f>Reading from Binary Files<:X8,7;Index "Files" # "reading, binary"><:X8,7;Index "Binary files" # "reading"><:X8,7;Index "Reading from files" # "binary">

@1st Paragraph@<:#200,8486><:f>To read data from a binary file, use either the Get statement or the Input function.

<:#1600,8486>The Get statement reads the correct number of bytes into any variable of known length, such as fixed-length strings or integers. For variable-length strings, the number of characters read equals the 
<+">current length<-"> of the string. (Note that this will be zero for uninitialized variable-length strings.) Therefore you should first set the current length to the length of the string to be read. If the string in the file is within a user-defined type,
 the string length was stored by LotusScript with the string. If the string is not within a user-defined type, then you must know the length independently. For example, you can have stored the length as a separate field with the string.

<:#200,8486>Input (or Input$) can also be used to read data from a binary file. The syntax is:

<:#200,8486><+"><:f>x<-"> = <+!>Input(<-!><+">num_bytes<-"><+!>,<-!> <+">file_number<-"><+!>)<-!>

<:#400,8486><:f>where <+">x<-"> is a Variant (Input) or String (Input$). This function reads 
<+">num_bytes<-"><:f,QCourier,> <:f>bytes from the file and returns them to the caller in variable 
<+">X<-">.

<:#200,8486><:f>

>

[Embedded]
00034617
