![]() |
|
||||||||
| Site Links |
| Consulting |
| Knowledge Base |
| Training |
| Forum |
| Articles |
| Resources |
| Products |
| Cool Tools |
| Contact |
| About Us |
| Go to Page... |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
|
Extract Substring, Ignore Substring for rest of txt, collect data while creating Data
Ok this is a pretty complicated question. I am given a txt file "Data.txt". It has a lot of these lines
[GPS: Central time,lat,dir,lon,dir,vel,cog,trk] 135921.00,3609.75843,N,09008.86165,W,N,,29 [GPS: Central time,lat,dir,lon,dir,vel,cog,trk] 235921.00,3809.79843,S,09008.86165,W,N,.01,29 What I'm wondering is how to extract each of the "Central Time" "lat" "dir" etc. from the file's first line(posting them to designated cells). Then ignoring them for the rest of the file while still extracting each of the "135921.00" "3609.75843" "N" etc (posting them into the cells below each other under the Titles "Central Time" "lat" etc). I keep getting confused as to which variables I'm using or if I'm even using them correctly. Any help would be appreciated |
|
Local Time: 09:13 AM
Local Date: 05-18-2013 Location:
|
|
|
|
#2 |
|
|
I am posting this reply cause I re-read and I realized I wasn't specific as to what I needed.
I just need to know how to extract the data from the first string then disregard it for the rest of the file. Then Read in every other even line for data. I can open the file for input and also post results into the spreadsheet. I'm just not to sure how to do the string parsing. |
|
Local Time: 09:13 AM
Local Date: 05-18-2013 Location:
|
|
|
|
#3 |
|
|
Code So Far
VBA:
VBA tags courtesy of www.thecodenet.com
|
|
Local Time: 09:13 AM
Local Date: 05-18-2013 Location:
|
|
![]() |
| Display Modes |
Linear Mode |
Switch to Hybrid Mode |
Switch to Threaded Mode |
|
|


