|
-
Jun 30th, 2000, 04:55 AM
#1
Thread Starter
New Member
Hi ho!
Anyone know of a quick way, besides writing a supporting .dll in c, to parse tokens out of a string delimited by an arbitrary number of tabs and spaces?
My function uses a few replace()-functions and a split()-function to get the tokens in to an array, but when there's something like 35 000 lines in a file, the wait gets a tad boresome for the user..
-
Jun 30th, 2000, 05:02 AM
#2
Fanatic Member
Time to write your own function methinks.
To get you started, here is an example of a very quick split function.
The basic principle is that you use a couple of pointer to bits of the string using InStr(), and then extarct the bit with mid$()
Need any more help, just ask.
Iain, thats with an i by the way!
-
Jun 30th, 2000, 06:36 AM
#3
Fanatic Member
hahahhaha
I knew that Iain17 would be here advertising that function of his again!!!
It is fast though, especially on large text strings
Paul Dwyer 
Network Engineer
Aussie In Tokyo
Using Powerbasic 6 & VB6 SP4 (Please also add your VB Version to your signature!)
-
Jun 30th, 2000, 06:40 AM
#4
Fanatic Member
Sorry. *hangs head in shame*
I can't seem to help myself. I can't help with a lot of problems becuse i know very little (ie nothing) about API, and some of the other questions.
What i am good at is writing algorithims for people, and when you find a good one, you want everyone to know about it.
Iain, thats with an i by the way!
-
Jun 30th, 2000, 06:48 AM
#5
Fanatic Member
I'm not too experianced with the API either, I've got a few books but not many projects that really need API, just a few little calls here and there.
Paul Dwyer 
Network Engineer
Aussie In Tokyo
Using Powerbasic 6 & VB6 SP4 (Please also add your VB Version to your signature!)
-
Jun 30th, 2000, 12:25 PM
#6
just thought I'd get a plug in while were on the subject:
My CSV ---> Fixed width control is nearly complete, will be available soon!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|