Jump to content

Cachemate & GSAK


Coach88

Recommended Posts

I don't get it...

 

When I run the Macro, it brings me to the log pages of the caches that I have already logged. I keep clicking on continue and it keeps opening the log pages going from the most recent to the oldest. When I stopped the macro and ran it again, I expected that it would continue from where I left off. It didn't. It started again from the most recent found cache?????

Link to comment

The macro is written to filter all "Found" coches. So if you have your newly "Found (and unlooged)" caches in the same database as the rest of your Found caches then the macro will try to log all the Found caches. There are a couple ways to get around this issue;

 

1) If you have a seperate database just for your "Found" caches then don't move your new "Found (unlogged)" to this "Found" Database until they have been logged. And don't run the logging macro against the "Found" Database

 

2) If you don't have or want a Found database, then we could modify the macro to ask for the date you that you want to log. There could be a possible issue with this setup, and that would be if you found caches today, the caches have been marked as found in GSAK and you have logged them on Goecaching, then later in the day you find a couple more caches. When you run the logging macro it will pull all the caches you found today including the ones you've already logged.

A) We might be able to come up with a work around but it may not be 100% effective.

Link to comment

N80FP-Del

 

When the Macro asks wich Database to move the found caches from, the name of my current database (Pocket Queries) is in the input field by default. When I run it, I get the following error message:

 

«Error log: 2007-01-28 09:32:18

********************************************************************

 

Current Macro: C:\Program Files\GSAK\Macros\log_on_gccom.txt

 

Error in Macro at line: 29

VIEW name="Home"

 

Error=> View not found: Home

 

Macro will now abort

--------------------------------------------------------------------

Variables:

--------------------------------------------------------------------

*Active Table* = caches

$_Count (numeric) =2780

$_CurrentDatabase (string) =Pocket Queries

$_Degrees (numeric) =151,31650827001

$_Eol (boolean) =False

$_FilterCount (numeric) =0

$_Install (string) =C:\Program Files\GSAK

$_MacroLevel (numeric) =2

$_NewLine (string) =|

$_Quote (string) ="

$_SortBy (string) =Foundbyme;Usersort=D

$_Today (date) =[20070128]

$_Version (string) =6.6.4.20

$CacheMateLog (string) =[TfmCmateLog]|rbtLog.Checked=False|rbtNo.Checked=False|rbtNotes.Checked=True|rbtYes.Checked=True|rbtReplace.Checked=False|rbtAdd.Checked=True|rbtFlagNo.Checked=False|rbtFlagYes.Checked=True|rbtDateOnly.Checked=False|rbtDateTime.Checked=False|rbtUserNo.Checked=False|rbtUserYes.Checked=True|rbtCode.Checked=True|rbtSmart.Checked=False|

$Database (string) =Pocket Queries

$MoveCopy (string) =[TfmMove]|cbxDestination.Text=Found|rbtAdd.Checked=True|rbtAddFlag.Checked=False|rbtAddIgnore.Checked=False|rbtCopy.Checked=False|rbtExistIgnore.Checked=False|rbtFlagOnly.Checked=False|rbtMove.Checked=True|rbtReplace.Checked=True|rbtReplaceFlag.Checked=False|chkDisplay.Checked=True|

$Path (string) =C:\Documents and Settings\ko

$Result (numeric) =2»

 

I tried to change it to the name of my found caches database and like before it tries to log ALL of my caches. I'm thinking the error log should be helpful to you...

Link to comment

Minor over sight on my part. The View=Home is a line of macro code that I have in my macro (which is where I took your macro from). There are a could ways we can fix this error.

 

1) With GSAK open to your Default database and and the database displayed the way you want it (All columns you want to see etc.) click on View > Save Current View. In the "Enter name for this view" type Home. Then click on OK

 

2) If you don't want to do that post your macro here and I will remove that line from the macro.

 

As for your other question about moving your found caches automatically to the found database, I believe I removed that protion of the macro. But it can be added in pretty easily. Simply post your macro here and I'll add the move function.

Link to comment

Coach88

 

After looking back through the make post here I found the original code I sent you and it does have the Move function in it.

 

I also found another item that may cause you a problem. There was a line in the macro that set the center point to Home. If you have not setup a center point in GSAK called home the macro will fail on that step as well. I have removed the View and Center lines from the macro code and the new code is posted below. Copy the code below and paste it in Note Pad, then save the file in the C:\Program Files\GSAK\Macros folder and call it the same name as you original Semi Automatic Logging macro. You will be asked if you want to over write the orignal, select Yes. Then run the macro against your Default database it will allow you to log the caches that are marked as found in your Default database and one they are all logged the macro will move them to the Found database.

 

Macro code

#####################################################################
# Semi-Automatic Log Found Caches On Geocaching.com
# Once All Found Caches Are Logged Move Found Caches To Found Database
#####################################################################

# Select Database
$Database = "Any string we know won't match a file name"
While .not. DatabaseExists($Database)
INPUT Msg="Enter the Database name that you want to move the Found Caches From." Default=$_CurrentDatabase VarName=$Database
If DatabaseExists($Database)
Database name=$Database Action=select
Else
Pause Msg="Database does not exist. Please try again"
EndIf
EndWhile

# Filter Found Caches
MFilter If=$d_Found
SORT By=Foundbyme;Usersort sequence=D
IF $_FilterCount > 0
GoTo Position=Top
While .not. $_eol
Else
ShowStatus msg="No Caches Marked As Found"

# Open Selected Database And Clear All User Flags
Database Name=$_CurrentDatabase Action=Select
USERFLAG type=clear range=all
SORT By=Distance Sequence=A
Cancel
ENDIF

# Copy contents of the log section of the notes for this cache into the clipboard
$LogData = $d_UserNote
$ClipData = $LogData
CLIP tags=$ClipData

# Call up the log page for this cache (press Ctrl-V to paste GSAK info the log box)
WEB url="http://www.geocaching.com/seek/log.aspx?ID=%gcid"
Pause msg="When your finished logging, click on continue"
GoTo Position=next
EndWhile
GoTo Position=Top

# Move Found Caches From Selected Database To Found Database
ShowStatus msg="Moving Found Caches To Found Database"
Database Name=$Database Action=Select
MFilter If=$d_Found
IF $_FilterCount > 0
   Macroset Dialog=MoveCopy VarName=$MoveCopy
MoveCopy Settings=<macro>
ENDIF

########################################################################
# Enbeded Settings

<data> VarName=$MoveCopy
[TfmMove]
cbxDestination.Text=Found
rbtAdd.Checked=True
rbtAddFlag.Checked=False
rbtAddIgnore.Checked=False
rbtCopy.Checked=False
rbtExistIgnore.Checked=False
rbtFlagOnly.Checked=False
rbtMove.Checked=True
rbtReplace.Checked=True
rbtReplaceFlag.Checked=False
chkDisplay.Checked=True
<enddata>

Link to comment

I upgraded to Version 7 and my macro doesn't work properly. I think the main problem is because i didn't install it over version 6 as I wanted to test 7 before registering and letting go of Version 6. I thought i had worked around it to a certain extent since I was able to get my finds from cachemate to GSAK. However when I use the log_on_gccom macro i get the following error on the gc.com page;

 

«Input string was not in a correct format.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

 

Exception Details: System.FormatException: Input string was not in a correct format.

 

Source Error:

 

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

 

Stack Trace:

 

[FormatException: Input string was not in a correct format.]

System.Number.ParseInt64(String s, NumberStyles style, NumberFormatInfo info) +0

Geocaching.UI.LogBookPanel.Page_Load(Object sender, EventArgs e) +2169

System.Web.UI.Control.OnLoad(EventArgs e) +67

System.Web.UI.Control.LoadRecursive() +35

System.Web.UI.Control.LoadRecursive() +98

System.Web.UI.Control.LoadRecursive() +98

System.Web.UI.Page.ProcessRequestMain() +750»

 

Any ideas???

Link to comment

This macro should run on either version 6.x.x or 7.x.x

I've been using version 7 for some time (Beta and public reelase). The macro code I posted was created, and tested on Version 7.

 

In fact I just copies the code from my last post and ran it using both version 6 and version 7 and it ran with out a problem. I suspect the problem is with your GSAK Version 7 install. Have you tried doing Database Refresh / Defrag? (Click on Database then click on Repair / Defrag.

Link to comment

I don't think I was clear enough in my previous post. What I was trying to say was that I didn't install GSAK in it's default location. I think that is creating some problems. The current path for version 7 is in My Documents\geocaching\NewFolder. I beleive the Macro is pointing to the default location wich would be Program files\GSAK...

 

Does this make any sense?

Link to comment

I just noticed that the code column doesn't have the typical GC..., instead it shows the smartname. I think that may be why when I try the log_on_gc.com macro it doesn't open the page for that cache but shows the error message that I refered to a few posts ago instead. Also, the name column shows «Geocache» instead of the actual cache name.

Link to comment

Yes that is an easy change. The code below has been changed to sort "Asending".

 

Just to explain what was done, I changed the User Sort from Desending to Asending in the following section of the macro;

 

# Filter Found Caches

MFilter If=$d_Found

SORT By=Foundbyme;Usersort sequence=A

IF $_FilterCount > 0

GoTo Position=Top

While .not. $_eol

Else

ShowStatus msg="No Caches Marked As Found"

 

#####################################################################
# Semi-Automatic Log Found Caches On Geocaching.com
# Once All Found Caches Are Logged Move Found Caches To Found Database
#####################################################################

# Select Database
$Database = "Any string we know won't match a file name"
While .not. DatabaseExists($Database)
INPUT Msg="Enter the Database name that you want to move the Found Caches From." Default=$_CurrentDatabase VarName=$Database
If DatabaseExists($Database)
Database name=$Database Action=select
Else
Pause Msg="Database does not exist. Please try again"
EndIf
EndWhile

# Filter Found Caches
MFilter If=$d_Found
SORT By=Foundbyme;Usersort sequence=A
IF $_FilterCount > 0
GoTo Position=Top
While .not. $_eol
Else
ShowStatus msg="No Caches Marked As Found"

# Open Selected Database And Clear All User Flags
Database Name=$_CurrentDatabase Action=Select
USERFLAG type=clear range=all
SORT By=Distance Sequence=A
Cancel
ENDIF

# Copy contents of the log section of the notes for this cache into the clipboard
$LogData = $d_UserNote
$ClipData = $LogData
CLIP tags=$ClipData

# Call up the log page for this cache (press Ctrl-V to paste GSAK info the log box)
WEB url="http://www.geocaching.com/seek/log.aspx?ID=%gcid"
Pause msg="When your finished logging, click on continue"
GoTo Position=next
EndWhile
GoTo Position=Top

# Move Found Caches From Selected Database To Found Database
ShowStatus msg="Moving Found Caches To Found Database"
Database Name=$Database Action=Select
MFilter If=$d_Found
IF $_FilterCount > 0
   Macroset Dialog=MoveCopy VarName=$MoveCopy
MoveCopy Settings=<macro>
ENDIF

########################################################################
# Enbeded Settings

<data> VarName=$MoveCopy
[TfmMove]
cbxDestination.Text=Found
rbtAdd.Checked=True
rbtAddFlag.Checked=False
rbtAddIgnore.Checked=False
rbtCopy.Checked=False
rbtExistIgnore.Checked=False
rbtFlagOnly.Checked=False
rbtMove.Checked=True
rbtReplace.Checked=True
rbtReplaceFlag.Checked=False
chkDisplay.Checked=True
<enddata>

Link to comment

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...