delimit string in a textfile
From: ht (harald_thomsen_at_yahoo.com)
Date: 10/31/04
- Next message: J French: "Re: Been a slice..."
- Previous message: VBDis: "Re: Try Finally..."
- Next in thread: Tom de Neef: "Re: delimit string in a textfile"
- Reply: Tom de Neef: "Re: delimit string in a textfile"
- Reply: J French: "Re: delimit string in a textfile"
- Reply: Ante Smolcic: "Re: delimit string in a textfile"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 31 Oct 2004 03:29:29 -0800
Hi,
I got a textfile that i'm reading into variables.
The file looks like this:
S: : : 1: 8:28/10/04 08:30:14: 16:
1:900030=:30:10000:4:1000:0:0:0:0:1:1:"":0:""
S: : : 1: 9:28/10/04 08:30:21: 16:
1:900030=:30:7500:1:1000:0:0:0:0:1:1:"":0:""
S: : : 1: 13:28/10/04 08:31:14: 16:
1:2069670000008:49:7525:1:4192:0:169:0:0:1:1:"":2069670075259:""
S: : : 1: 14:28/10/04 08:31:18: 16:
1:2068130000008:49:1230:1:62:0:0:0:0:1:1:"":2068130012308:""
S: : : 1: 18:28/10/04 08:31:25: 16:
1:421=:30:1580:4:1000:0:118:0:0:1:1:"":0:""
S: : : 1: 19:28/10/04 08:31:27: 16:
1:5704068025016:47:1095:1:1000:0:0:0:0:1:1:"":0:""
E: : : 1: 24:28/10/04 08:31:42: 16: 1:85:0:76875:""
T: : : 1: 28:28/10/04 08:31:46: 16: 1:7:76875:1:0:0:"17"
I: : : 1: 29:28/10/04 08:31:46: 16:
1:27:77060:0:0:0:0:1:76875:0:0:0:0:1
E: : : 1: 30:28/10/04 08:31:46: 16: 1:84:0:0:""
E: : : 1: 31:28/10/04 08:34:14: 16: 0:90:83:0:""
Every line starts with a letter.
In the first half I can use
date := copy(S, 20, 8)
as the colons are in fixed places.
Can I find the colons using Pos, and then use Copy to get it?
Not sure how it's done.
Using D5
Regards,
Harald
- Next message: J French: "Re: Been a slice..."
- Previous message: VBDis: "Re: Try Finally..."
- Next in thread: Tom de Neef: "Re: delimit string in a textfile"
- Reply: Tom de Neef: "Re: delimit string in a textfile"
- Reply: J French: "Re: delimit string in a textfile"
- Reply: Ante Smolcic: "Re: delimit string in a textfile"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|