MArket under2,5

Please post any questions regarding the program here.

Moderator: 2020vision

MArket under2,5

Postby Revol82 » Fri May 27, 2011 11:57 pm

Hi all

Is it possible on bet assistant to get all under2,5 markets of the day? Before the In-Play.
Revol82
 
Posts: 8
Joined: Fri May 27, 2011 11:55 pm

Re: MArket under2,5

Postby Revol82 » Sat May 28, 2011 5:56 pm

...Soccer MArkets :P
Revol82
 
Posts: 8
Joined: Fri May 27, 2011 11:55 pm

Postby GaryRussell » Sun May 29, 2011 12:22 pm

Not exactly sure what you are asking. Do you mean display them all at the same time or add them to the quick pick list?
User avatar
GaryRussell
Site Admin
 
Posts: 9872
Joined: Fri Nov 18, 2005 8:09 pm
Location: Birmingham, UK

Postby Revol82 » Sun May 29, 2011 10:54 pm

I need to send two markets to excel sheet, the under/over 2,5 and the correct score market. The u/o is actually easy, i didnt notice that there was an option in the coupon markets, though i think theres no option to the cs market right?
Revol82
 
Posts: 8
Joined: Fri May 27, 2011 11:55 pm

Postby GaryRussell » Mon May 30, 2011 8:49 am

Correct. There is no option for the correct score market. Maybe in a future release.
User avatar
GaryRussell
Site Admin
 
Posts: 9872
Joined: Fri Nov 18, 2005 8:09 pm
Location: Birmingham, UK

Postby Revol82 » Fri Jun 03, 2011 5:20 pm

Thank you Gary...

Im still newbie at VBA.
Im trying to build a macro that clears my bet ref when the market gets suspended. My problem is that i want the macro to constantly monitor until it finds "suspended" in F2, and i can only set it when i press "run" at the macro
Revol82
 
Posts: 8
Joined: Fri May 27, 2011 11:55 pm

Postby Revol82 » Sat Jun 04, 2011 2:50 am

Well...sorted

But have another problem: im getting the error: Method default of object range failed

Code: Select all
Private Sub Worksheet_Change(ByVal Target As Range)

If Range("F2").Value = "Suspended" Then
Sheet4.Cells(5, 17) = ""
Sheet4.Cells(5, 18) = ""
Sheet4.Cells(5, 19) = ""
Sheet4.Cells(5, 20) = ""
Sheet4.Cells(6, 17) = ""
Sheet4.Cells(6, 18) = ""
Sheet4.Cells(6, 19) = ""
Sheet4.Cells(6, 20) = ""
Sheet4.Cells(9, 17) = ""
Sheet4.Cells(9, 18) = ""
Sheet4.Cells(9, 19) = ""
Sheet4.Cells(9, 20) = ""
Sheet4.Cells(10, 17) = ""
Sheet4.Cells(10, 18) = ""
Sheet4.Cells(10, 19) = ""
Sheet4.Cells(10, 20) = ""

End If

End Sub
Revol82
 
Posts: 8
Joined: Fri May 27, 2011 11:55 pm

Postby GaryRussell » Sat Jun 04, 2011 6:13 am

Your code would be better as follows. Don't know if it will solve your problem without seeing it in the context of your actual spreadsheet.

Code: Select all
Private Sub Worksheet_Change(ByVal Target As Range)
    If Target.Columns.Count = 16 Then
        If Range("F2").Value = "Suspended" Then
            Application.EnableEvents = False
            Sheet4.Cells(5, 17) = ""
            Sheet4.Cells(5, 18) = ""
            Sheet4.Cells(5, 19) = ""
            Sheet4.Cells(5, 20) = ""
            Sheet4.Cells(6, 17) = ""
            Sheet4.Cells(6, 18) = ""
            Sheet4.Cells(6, 19) = ""
            Sheet4.Cells(6, 20) = ""
            Sheet4.Cells(9, 17) = ""
            Sheet4.Cells(9, 18) = ""
            Sheet4.Cells(9, 19) = ""
            Sheet4.Cells(9, 20) = ""
            Sheet4.Cells(10, 17) = ""
            Sheet4.Cells(10, 18) = ""
            Sheet4.Cells(10, 19) = ""
            Sheet4.Cells(10, 20) = ""
            Application.EnableEvents = True
        End If
    End If
End Sub

Note that it only runs when 16 columns have been updated which is when cell F2 is updated. Also it disables events while your code is updating cells. This to prevent Worksheet_Change being called again while your code is still updating the cells.
User avatar
GaryRussell
Site Admin
 
Posts: 9872
Joined: Fri Nov 18, 2005 8:09 pm
Location: Birmingham, UK

Postby Revol82 » Sat Jun 04, 2011 3:07 pm

ty Gary, works now.

just one more question... how can i put the range instead of range ("F2") sonething like range("F2:F11")...i want to monitor more than one cell. just changing in code is not working, have a type mismatch error.
Revol82
 
Posts: 8
Joined: Fri May 27, 2011 11:55 pm

Postby GaryRussell » Sun Jun 05, 2011 8:41 am

You cannot compare a range to one value. You need to look at the individual cells within the range.

eg. If F2 contains "A" and F3 contains "B" then:-

Range("F2:F11").Cells(1,1) = "A"
Range("F2:F11").Cells(2,1) = "B"
User avatar
GaryRussell
Site Admin
 
Posts: 9872
Joined: Fri Nov 18, 2005 8:09 pm
Location: Birmingham, UK


Return to Help

Who is online

Users browsing this forum: No registered users and 91 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.