Moderator: 2020vision
by willow59 » Fri Apr 02, 2021 10:27 am
by MollyMoo » Sat Apr 03, 2021 12:04 pm
'Place these 3 lines in a Module
Public StartTime As Double
Public RaceHasStarted As Boolean
Public Greened As Boolean
'Routine which runs when a new race is loaded from Quick Pick List
Private Sub Worksheet_Change(ByVal Target As Range)
Greened = False
RaceHasStarted = False
End Sub
'Routine which runs when sheet calculates
'Or place code in Worksheet_Change subroutine if running every time odds change
'Code assumes Gruss is connected to Cell A1
Private Sub Worksheet_Calculate()
Dim lastRow As Integer, i As Integer
'Replace "SheetConnectedToGruss" with the name of your worksheet connected to Gruss
With ThisWorkbook.Sheets("SheetConnectedToGruss")
If Not RaceHasStarted And .Range("E2") = "In Play" Then
RaceHasStarted = True
StartTime = Timer
End If
If RaceHasStarted And Not Greened And Timer - StartTime >= 10 Then
lastRow = .Cells(.Rows.Count, 1).End(xlUp).row
For i = 5 To lastRow
If .Range("Q" & i) <> vbNullString Then .Range("Q" & i) = "CLOSEC"
Next i
Greened = True
End If
End Sub
by MollyMoo » Sat Apr 03, 2021 12:21 pm
MollyMoo wrote:Try this:
- Code: Select all
'Place these 3 lines in a Module
Public StartTime As Double
Public RaceHasStarted As Boolean
Public Greened As Boolean
'Routine which runs when a new race is loaded from Quick Pick List
Private Sub Worksheet_Change(ByVal Target As Range)
Greened = False
RaceHasStarted = False
End Sub
'Routine which runs when sheet calculates
'Or place code in Worksheet_Change subroutine if running every time odds change
'Code assumes Gruss is connected to Cell A1
Private Sub Worksheet_Calculate()
Dim lastRow As Integer, i As Integer
'Replace "SheetConnectedToGruss" with the name of your worksheet connected to Gruss
With ThisWorkbook.Sheets("SheetConnectedToGruss")
If Not RaceHasStarted And .Range("E2") = "In Play" Then
RaceHasStarted = True
StartTime = Timer
End If
If RaceHasStarted And Not Greened And Timer - StartTime >= 10 Then
lastRow = .Cells(.Rows.Count, 1).End(xlUp).row
For i = 5 To lastRow
If .Range("Q" & i) <> vbNullString Then .Range("Q" & i) = "CLOSEC"
Next i
Greened = True
End If
End With
End Sub
by vanbuuts » Tue Apr 13, 2021 6:49 pm
by MollyMoo » Tue Apr 20, 2021 10:48 pm
by MollyMoo » Tue Apr 20, 2021 11:20 pm
Private Sub Worksheet_Calculate()
Application.EnableEvents = False
Dim lastRow As Integer, i As Integer
'Replace "SheetConnectedToGruss" with the name of your worksheet connected to Gruss
With ThisWorkbook.Sheets("SheetConnectedToGruss")
If Not RaceHasStarted And .Range("E2") = "In Play" Then
RaceHasStarted = True
StartTime = Timer
End If
If RaceHasStarted And Not Greened And Timer - StartTime >= 10 Then
lastRow = .Cells(.Rows.Count, 1).End(xlUp).row
For i = 5 To lastRow
If .Range("Q" & i) <> vbNullString Then .Range("Q" & i) = "CLOSEC"
Next i
Greened = True
End If
End With
Application.EnableEvents = True
End Sub
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.