+w1qa Posted March 14, 2004 Share Posted March 14, 2004 Some time ago I came up with a very simple system for my own home grown Geocaching (and benchmark) tracking and mapping system. Here's how it worked: - weekly query generates 3282.LOC and 3418.LOC files - LOC2CSV.VBE converted them to CSV files - imported into Microsoft Access - merged inport file into appropriate table (no dupes) - ran a query to identify which caches (or benchmarks) were new My Geocaching Access table had the Latitude, Longitude, Information (URL to cache), Name (GCxxxx), Name2 (cache description) ... and a field called Status which I added to this flat file. The Status field contained values like: Cache (for a cache), Logged (for one I found), New (for one that's been newly imported), Archived, Hidden and Seek. I then use Microsoft MapPoint and link directly to the Access database. MapPoint displays each cache; the cache's icon depends on the status field in the database (different shape, colour, etc.) There's also a similar table for benchmarks ... I used to make all my decisions on caches and benchmarks to seek by working with the MapPoint map: just seems like the logical way to view it! And each cache and benchmark had a clickable URL that would (using the Information field) launch a web browser window for that cache (or benchmark). Sometime in the fall of last year I think something with the LOC files changed ... dropping the .LOC file onto the LOC2CSV programme generates the error: Wrong format. Tells me to open the .loc-file in notepad and verify that the file begins with "<?xml". If it does, please report the error to the author. The .LOC file does: <?xml version="1.0" encoding="ISO-8859-1"?> I sent a message off to the author ... but never heard back. I've searched around - but have not found anything that will convert this .LOC file from my queries to the flat file I'd like ... in order to continue importing to my database. I've looked at a couple of queries generated with the GPX format ... but more infomration and a bit more complicated than what I'm looking for. Specific comments about that: The URL has the very long GUID and not the simple details by 6-character cache or benchmark waypoint name. The description really combines TWO fields: the owner and the cache name Any pointers and suggestions would be greatly appreciated. Although I'd like to keep my simple access database as-is, I'm not against moving to something else ... the main criteria is being able to plot everything in MapPoint (with some ability to indicate what's been found) - and frequently update that information. Thanks in advance for any assistance. Quote Link to comment
Swagger Posted March 14, 2004 Share Posted March 14, 2004 I'm not against moving to something else ... the main criteria is being able to plot everything in MapPoint (with some ability to indicate what's been found) - and frequently update that information. This might be useful to you. Is LOC2CSV.VBE just a VB script? If it's not compiled code, you could just find where it's gronking and fix it. Quote Link to comment
+Volwrath Posted March 14, 2004 Share Posted March 14, 2004 Look, at GPSBabel as well. It seems to be able to convert from just about anything to just about anything. A batch file could easily be set up. Quote Link to comment
+w1qa Posted March 17, 2004 Author Share Posted March 17, 2004 Is LOC2CSV.VBE just a VB script? If it's not compiled code, you could just find where it's gronking and fix it. Yes, the VBE file is compiled - so I know of no ways to change it. (I'm also really not too familiar with programming with today's tools - my programming skills are back a couple of decades on old DECSystem-10's and PDP-11's.) This is what's in the start of the VBE file: '**************************************************************** '* * '* This script reads .loc-files from Groundspeak.com and * '* converts them into .csv-files suitable for import into * '* Microsoft Mappoint 2002 * '* * '* Comments, suggestions and error reports are welcome. * '* * '* Per K. Nielsen * '* geocacher -at- pknielsen.dk * '* http://pknielsen.dk/geocaching/ * '* * '* Version 1.5 * '* * '**************************************************************** (I've munged his email address above). I wrote to Per Nielsen some time ago but didn't get any response. I don't think his web presence has been updated at all, either. I'll check out that link you provided and see if that helps! Quote Link to comment
+elmo-fried Posted March 17, 2004 Share Posted March 17, 2004 (edited) Look, at GPSBabel as well. It seems to be able to convert from just about anything to just about anything. A batch file could easily be set up. In fact I use it for just this application and I've used the "Link Data Wizard" to the CSV file. Note that I'm using GPX files and not LOC files: Here's the syntax: gpsbabel.exe -s -i gpx -f 35909.gpx -o csv -F 35909.csv I just have a PQ for "found caches" and another for "haven't found" and I have two different pushpin icons for each CSV that is using the "Link Data Wizard." Sure, this isn't as good as the home-grown system you're talking about, but I've found between MapPoint and Watcher I'm all set. I have links, screenshots and scripts of some of the stuff I do on the webpage in my sig. Edited March 17, 2004 by elmo-fried Quote Link to comment
+trippy1976 Posted March 17, 2004 Share Posted March 17, 2004 Get GSAK. Geocaching Swiss Army Knife. You can export to a .csv file. Then use the Data Import feature of mappoint to do a direct import of the points. Steps: 1. Download and install GSAK 2. Get GPX files 3. Start GSAK 4. Load GPX file(s) 5. Go to File --> Export --> Microsoft Streets & Trips CSV File... 6. Open MapPoint 7. Go to Data --> Import Data Wizard... --> Follow wizard to import set I'm not sure if you get different icons this way or not to be honest. It'll save you a lot of hassle I think though. I only import my unfound. Then I do the same thing you do as far as planning. It sounds complicated but after the first time, it takes like 5 minutes. Quote Link to comment
+elmo-fried Posted March 17, 2004 Share Posted March 17, 2004 Get GSAK. Geocaching Swiss Army Knife. You can export to a .csv file. Then use the Data Import feature of mappoint to do a direct import of the points. Steps: 1. Download and install GSAK 2. Get GPX files 3. Start GSAK 4. Load GPX file(s) 5. Go to File --> Export --> Microsoft Streets & Trips CSV File... 6. Open MapPoint 7. Go to Data --> Import Data Wizard... --> Follow wizard to import set I'm not sure if you get different icons this way or not to be honest. It'll save you a lot of hassle I think though. I only import my unfound. Then I do the same thing you do as far as planning. It sounds complicated but after the first time, it takes like 5 minutes. While this might work (and I'm going to check out GSAK as it looks very cool), the gpsbabel solution I talked about can be totally automated in a batch file/shell script and requires no user intervention. It takes <2 seconds with gpsbabel to convert a 500-Geocache GPX to EST for Microsoft Streets and Trips 2002/2003 (or generic CSV as I said in the post above): gpsbabel.exe -s -i gpx -f ../55388/55388.gpx -o s_and_t -F ../55388/55388.est Here's a timed session under cygwin (AMD 1.788GHz, not sure the processor model): $ echo Start: `date`; ./gpsbabel.exe -s -i gpx -f ../55388/55388.gpx -o s_and_t -F ../55388/55388.est; echo Stop : `date` Start: Wed Mar 17 14:00:31 PST 2004 Stop : Wed Mar 17 14:00:32 PST 2004 If you only process one PQ once per weekend, doing things manually might not be a big deal. However, I actually have 7 different PQs that cover 2400 caches over about a 150 miles radius from my house. I download 5 per day Fri-Sun, and I'd hate to manually process each one. Also, depending on your email situation, you could automate the downloading/exporting of the PQ email. I've not yet done this, but it wouldn't be handy to have done so a single click would update all my offline GC.com data. gpsbabel supports a ton of different input/output formats (including Microsoft Streets and Trips, but I've never used that format). There is a front-end GUI for those that fear the CLI, but again, it think that defeats the purpose of using a powerful CLI tool. $ ./gpsbabel.exe -? GPSBabel Version 1.1.1_beta08122003. http://gpsbabel.sourceforge.net Usage: d:\personal\fun\geocaching\gpsbabel-1.1.1_beta08142003\gpsbabel.exe [options] -i INTYPE -f INFILE -o OUTTYPE -F OUTFILE d:\personal\fun\geocaching\gpsbabel-1.1.1_beta08142003\gpsbabel.exe [options] -i INTYPE -o OUTTYPE INFILE [OUTFILE] Converts GPS route and waypoint data from one format type to another. The input type and filename are specified with the -i INTYPE and -f INFILE options. The output type and filename are specified with the -o OUTTYPE and -F OUTFILE options. In the second form of the command, INFILE and OUTFILE are the first and second positional (non-option) arguments. Options: -s Synthesize shortnames -r Process route information -t Process track information -w Process waypoint information [default] -x filtername Invoke filter -D level Set debug level [0] File Types (-i and -o options): xcsv ? Character Separated Values style Full path to XCSV style file (required) snlen Max synthesized shortname length snwhite (0/1) Allow whitespace synth. shortnames snupper (0/1) UPPERCASE synth. shortnames snunique (0/1) Make synth. shortnames unique urlbase Basename prepended to URL on output prefer_shortnames Use shortname instead of description geo Geocaching.com .loc gpx GPX XML gsshortnames Prefer shorter descriptions from Groundspeak files snlen Length of generated shortnames suppresswhite Suppress whitespace in generated shortnames magellan Magellan protocol baud Numeric value of bitrate (baud=4800) noack Suppress use of handshaking in name of speed deficon Default icon name mapsend Magellan Mapsend pcx Garmin PCX5 deficon Default icon name mapsource Garmin Mapsource snlen Length of generated shortnames gpsutil gpsutil psp MS PocketStreets 2002 Pushpin cetus Cetus for Palm/OS dbname Database name copilot CoPilot Flight Planner for Palm/OS gpspilot GPSPilot Tracker for Palm/OS dbname Database name magnav Magellan NAV Companion for PalmOS garmin Garmin serial protocol holux Holux (gm-100) .wpo Format tpg National Geographic Topo .tpg tmpro TopoMapPro Places File gcdb Geocaching Database tiger U.S. Census Bureau Tiger Mapping Service nolabels Suppress labels on generated pins. genurl Generate file with lat/lon for centering map. scale Dimension in pixels of map. easygps EasyGPS quovadis Quovadis dbname Database name gpilots GpilotS dbname Database name xmapwpt Delorme XMat HH Street Atlas USA .WPT (PPC) xmap Delorme XMap HH Native .WPT s_and_t Microsoft Streets and Trips 2002/2003 ozi OziExplorer Waypoint nima NIMA/GNIS Geographic Names File mxf MapTech Exchange Format mapconverter Mapopolis.com Mapconverter CSV gpsman GPSman gpsdrive GpsDrive Format fugawi Fugawi dna Navitrak DNA marker format custom Custom "Everything" Style csv Comma separated values arc GPSBabel arc filter file Supported data filters: position Remove Points Within Distance distance Maximum positional distance (required) radius Include Only Points Within Radius lat Latitude for center point (D.DDDDD) (required) lon Longitude for center point (D.DDDDD) (required) distance Maximum distance from center (required) exclude Exclude points close to center duplicate Remove Duplicates shortname Suppress duplicate waypoints based on name location Suppress duplicate waypoint based on coords arc Include Only Points Within Distance of Arc file File containing vertices of arc (required) distance Maximum distance from arc (required) exclude Exclude points close to the arc polygon Include Only Points Inside Polygon file File containing vertices of polygon (required) exclude Exclude points inside the polygon Quote Link to comment
+elmo-fried Posted March 17, 2004 Share Posted March 17, 2004 Going OT here, but I've been playing with GSAK for the last hour or so. Looks great, and what I like the most so far is the internal DB it maintains of caches. Still getting used to the differences vs. Watcher, but a big thumbs up thus far. It even handled the importing of Benchmarks (downloaded from NGS and then converted to GPX with Fuzzy's bmgpx. I just wish it would allow you to set the cache-type on import (it sets it to mystery, and if they added a BM icon that'd be great). Quote Link to comment
Dinoprophet Posted March 17, 2004 Share Posted March 17, 2004 I have written a MapPoint addin that imports Pocket Query GPX files. It doesn't have all the features that Waypoint Importer has, but it does let you specify the pushpin groups by cache type. Email me through the site if you'd like a copy (no charge). Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.