Excel refreshes

Discuss anything related to using the program (eg. triggered betting tactics)

Moderator: 2020vision

Excel refreshes

Postby Frinck » Sun Mar 16, 2008 11:39 pm

I've been having a long-running issue with the refreshes in Excel and I'm hoping to understand what's happnening. Here's the problem...

The standard way that I use to tell if a refresh has been made is to use the following code in a Worksheet_Change:

If Target.Columns.Count = 16 Then
... carry on with processing
Else
... refresh not complete
End If

The problem I get is that even if the first refresh for a race appears to have completed ok, the runner details are not always up-to-date, ie. horse names are from a different race and/or prices are 0 or far too low. I can (and do) check for prices being non-0 pre race (not in-play) but can't verify horse names and odds when they're obviously wrong.

Note that this seems to happen on every first refresh for a given race, and intermittently on subsequent refreshes.

The end result is that my routines will only get processed when the target column count is 16, the back odds 1 for the top horse (f5) is not 0 and the refresh count for each specific race is greater than 1. It's a bit messy and not as straightforward as I was hoping it would be.

Does anyone else suffer from this problem? Maybe people aren't noticing it due to the way their workbooks work - to the naked eye, its undetectable.

I'd really like to understand why this is happening and if there's anything I can do to make my code cleaner and more reliable.

Any help would be much appreciated.
Cheers,
Frinck.
Frinck
 
Posts: 67
Joined: Sun Aug 13, 2006 11:49 pm

Postby jokerjoe » Mon Apr 14, 2008 4:05 pm

Having similar issues too. Been running a script to log prices and notice that some prices get wiped on changing race. Also trying to pull data from another workbook upon market change but it appears to be grabbing data for horses from the last race too.

Would also appreciate an explanation of how BA refreshes Excel.

Thanks.
User avatar
jokerjoe
 
Posts: 122
Joined: Wed May 09, 2007 12:00 pm

Postby GaryRussell » Tue Apr 15, 2008 5:26 pm

I am currently investigating this.
User avatar
GaryRussell
Site Admin
 
Posts: 9872
Joined: Fri Nov 18, 2005 8:09 pm
Location: Birmingham, UK

Postby GaryRussell » Tue Apr 15, 2008 6:20 pm

I think I have found the source of this problem. Excel is updated on a background thread. When switching markets the program was not waiting for the thread to finish so it was possible that the background thread could update Excel with data from the previous market after BA had switched markets. I will release a fix for this tomorrow.
User avatar
GaryRussell
Site Admin
 
Posts: 9872
Joined: Fri Nov 18, 2005 8:09 pm
Location: Birmingham, UK

Postby jokerjoe » Tue Apr 15, 2008 6:28 pm

Thanks, looking forward to seeing it's effect.
User avatar
jokerjoe
 
Posts: 122
Joined: Wed May 09, 2007 12:00 pm

Postby GaryRussell » Wed Apr 16, 2008 10:58 am

It's fixed in version 1.1.0.5. Also there's a bonus feature, you can now log your current bets to a worksheet, just provide a worksheet named 'MyBets'
User avatar
GaryRussell
Site Admin
 
Posts: 9872
Joined: Fri Nov 18, 2005 8:09 pm
Location: Birmingham, UK

Postby mike » Mon Apr 21, 2008 9:41 pm

That's a great bonus Gary! Thank's a lot!

regards,
Mike
mike
 
Posts: 120
Joined: Sat Dec 30, 2006 2:36 pm

Postby jokerjoe » Mon May 19, 2008 12:14 pm

Gary, only just tested the changes as was using a workaround, sheets working as expected now, many thanks! And mybets feature proving to be really useful too. :D
User avatar
jokerjoe
 
Posts: 122
Joined: Wed May 09, 2007 12:00 pm


Return to Discussion

Who is online

Users browsing this forum: Bing [Bot] and 57 guests

Sports betting software from Gruss Software


The strength of Gruss Software is that it’s been designed by one of you, a frustrated sports punter, and then developed by listening to dozens of like-minded enthusiasts.

Gruss is owned and run by brothers Gary and Mark Russell. Gary discovered Betfair in 2004 and soon realised that using bespoke software to place bets was much more efficient than merely placing them through the website.

Gary built his own software and then enhanced its features after trialling it through other Betfair users and reacting to their improvement ideas, something that still happens today.

He started making a small monthly charge so he could work on it full-time and then recruited Mark to help develop the products and Gruss Software was born.

We think it’s the best of its kind and so do a lot of our customers. But you can never stand still in this game and we’ll continue to improve the software if any more great ideas emerge.