Techy Stuff

PQGenerator

GSAK Macro

GSAK (Geocaching Swiss Army Knife) is a powerful waypoint management tool for storing, filtering and managing geocaching waypoints.
For the past few months i’ve been holding a database of all the Geocaches in the UK. This requires me to keep renetering pocket queries which each contain the information for upto 500 geocaches.
These are filtered by date placed, and currently there is about 110 different queries requried to cover the whole of the UK. As a premium member it is possible to queue up 40 pocket queries.

With this in mind, I set about a way of speeding up setting up these queries.

Firstly, as there are caches being archived all the time I needed a way to get a complete list of the current caches, this I achieved by making a macro in GSAK as follows:
#*******************************************
# MacVersion = 1.0
# MacDescription = PQ Date Creator
# MacAuthor = Gareth
# MacFileName = PQCreator.gsk
# MacUrl =
#*******************************************

$output=""+$_NewLine
$output=$output+""+$_NewLine

MFILTER Expression=not($d_found) and not($d_Archived)
SORT by="placeddate"
$start=$d_PlacedDate
$i=1
$ended=false
While $ended=false

Goto Position=500
$end=$d_PlacedDate
#PAUSE Msg=DateFormat($start)+" - "+DateFormat($end)
MFILTER Expression=$d_PlacedDate>=$start and $d_PlacedDate<=$end and not($d_Found) and not($d_OwnerName="gse1986") and not($d_Archived)
SORT by="placeddate"
If $_FilterCount>500
$end=$end-1
#MsgOK msg="checked if filter"+DateFormat($end)+DateFormat($start)
MFILTER Expression=$d_PlacedDate>=$start and $d_PlacedDate<=$end and not($d_Found) and not($d_OwnerName="gse1986") and not($d_Archived)
SORT by="placeddate"
EndIf
IF $_FilterCount=0
#PAUSE Msg="No waypoints in filter, action cancelled"
endIf

If $i<10
$out="00"+NumToStr($i)
Else
If $i<100
$out="0"+NumToStr($i)
ELSE
$out=NumToStr($i)
EndIf
EndIf

$output=$output+""+$_NewLine+"allUK-"+$out+""+$_NewLine
$output=$output+""+DateFormat($start)+""+$_NewLine
$output=$output+""+DateFormat($end)+""+$_NewLine
$output=$output+""+NumToStr($_FilterCount)+""+$_NewLine
$output=$output+"
"+$_NewLine
SET $Data = PutFile($_Install + "\PQ.XML",$output)
$i=$i+1
$start=$end+1
MFILTER Expression=$d_PlacedDate>=$start and not($d_Found) and not($d_OwnerName="gse1986") and not($d_Archived)
SORT by="placeddate"
IF $_FilterCount > 0

ELSE
$ended=true
ENDIF
EndWhile

$output=$output+""+$_NewLine
SET $Data = PutFile($_Install + "\PQ.HTML",$output)

IF Left($Data,7) = "*Error*"
Pause Msg="$Data"
Cancel
ENDIF

Snow Day!

Woke up this morning to find moving the car quite interesting (I moved 3 foot and then got stuck!). Finally heard off the school it was closed today because of the weather so 4 months in to teaching and already a snow day :D

Today now need to do some lesson planning and also try and solved some of the issues with wordpress on the explorer website. Despite this site and the explorer site being set up identically, the explorer site seems to dislike being updated…at all.

Hopefully will be able to find a solution :)

Gareth

gps-const-lg

Dissertation

I’ve chosen my dissertation topic now and it’s going to be based around mobile applications and location based software. The program i’m going to be writing is going to be based around Geocaching. I’m hoping to add more details and progress to this blog as it goes along. So check back soon :)