Moderator: 2020vision
by samhayer » Mon Sep 07, 2020 5:41 pm
by Captain Sensible » Mon Sep 07, 2020 7:24 pm
Option Explicit
Public Today As Date, triggerQuickPickListReload As Boolean, triggerFirstMarketSelect As Boolean
Private Sub Worksheet_Change(ByVal Target As Range)
Static MyMarket As Variant
Static switched As Variant
If Target.Columns.Count <> 16 Then Exit Sub
Application.EnableEvents = False
Application.Calculation = xlCalculationManual
If Today <> Date Then
Today = Date
triggerQuickPickListReload = True
End If
If triggerQuickPickListReload Then
triggerQuickPickListReload = False
Worksheets("Sheet1").Range("Q2").Value = -3
triggerFirstMarketSelect = True
Else
If triggerFirstMarketSelect Then
triggerFirstMarketSelect = False
Worksheets("Sheet1").Range("Q2").Value = -5
End If
End If
Application.EnableEvents = True
Application.Calculation = xlCalculationAutomatic
End Sub
by Captain Sensible » Mon Sep 07, 2020 7:37 pm
Option Explicit
Public Today As Date, triggerQuickPickListReload As Boolean, triggerFirstMarketSelect As Boolean
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Columns.Count <> 16 Then Exit Sub
Application.EnableEvents = False
Application.Calculation = xlCalculationManual
If Today <> Date Then
Today = Date
triggerQuickPickListReload = True
End If
If triggerQuickPickListReload Then
triggerQuickPickListReload = False
Worksheets("Sheet1").Range("Q2").Value = -3
triggerFirstMarketSelect = True
Else
If triggerFirstMarketSelect Then
triggerFirstMarketSelect = False
Worksheets("Sheet1").Range("Q2").Value = -5
End If
End If
Application.EnableEvents = True
Application.Calculation = xlCalculationAutomatic
End Sub
by samhayer » Tue Sep 08, 2020 2:15 am
by Captain Sensible » Tue Sep 08, 2020 12:38 pm
Option Explicit
Public Today As Date, triggerQuickPickListReload As Boolean, triggerFirstMarketSelect As Boolean
Public currentMarket As String ' best to be a public variable so can be accessed by any routine
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Columns.Count <> 16 Then Exit Sub
Application.EnableEvents = False ' stopping events here mean we don't need to repeat it elsewhere
Application.Calculation = xlCalculationManual '
If Worksheets("Sheet1").Range("A1").Value <> currentMarket Then
currentMarket =Worksheets("Sheet1").Range("A1").Value ' usually best to write the full address in case the sheet is focussed on another sheet
logBalance
Call Macro2
Call Macro4
Call Macro5
End If
Call reloadQPL
Application.EnableEvents = True ' turn events back on
Application.Calculation = xlCalculationAutomatic
End Sub
Sub logBalance()
Dim r As Integer
r = 2
While Sheet2.Cells(r, 1) <> ""
r = r + 1
Wend
Sheet2.Cells(r, 1) = currentMarket
Sheet2.Cells(r, 2) = Worksheets("Sheet1").Range("I2").Value
End Sub
Sub reloadQPL()
If Today <> Date Then
Today = Date
triggerQuickPickListReload = True
End If
If triggerQuickPickListReload Then
triggerQuickPickListReload = False
Worksheets("Sheet1").Range("Q2").Value = -3
triggerFirstMarketSelect = True
Else
If triggerFirstMarketSelect Then
triggerFirstMarketSelect = False
Worksheets("Sheet1").Range("Q2").Value = -5
End If
End If
End Sub
by Captain Sensible » Tue Sep 08, 2020 12:57 pm
Option Explicit
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Columns.Count <> 16 Then Exit Sub
Application.EnableEvents = False ' stopping events here mean we don't need to repeat it elsewhere
Application.Calculation = xlCalculationManual '
If Worksheets("Sheet1").Range("A1").Value <> currentMarket Then
currentMarket =Worksheets("Sheet1").Range("A1").Value ' usually best to write the full address in case the sheet is focussed on another sheet
logBalance
Call Macro2
Call Macro4
Call Macro5
End If
Call reloadQPL
Application.EnableEvents = True ' turn events back on
Application.Calculation = xlCalculationAutomatic
End Sub
Option Explicit
Public Today As Date, triggerQuickPickListReload As Boolean, triggerFirstMarketSelect As Boolean
Public currentMarket As String ' best to be a public variable so can be accessed by any routine
Sub logBalance()
Dim r As Integer
r = 2
While Sheet2.Cells(r, 1) <> ""
r = r + 1
Wend
Sheet2.Cells(r, 1) = currentMarket
Sheet2.Cells(r, 2) = Worksheets("Sheet1").Range("I2").Value
End Sub
Sub reloadQPL()
If Today <> Date Then
Today = Date
triggerQuickPickListReload = True
End If
If triggerQuickPickListReload Then
triggerQuickPickListReload = False
Worksheets("Sheet1").Range("Q2").Value = -3
triggerFirstMarketSelect = True
Else
If triggerFirstMarketSelect Then
triggerFirstMarketSelect = False
Worksheets("Sheet1").Range("Q2").Value = -5
End If
End If
End Sub
by samhayer » Tue Sep 08, 2020 1:49 pm
by samhayer » Wed Sep 09, 2020 10:36 am
by Captain Sensible » Wed Sep 09, 2020 11:00 am
samhayer wrote:
and am I right to think I should paste the below into Mod1
Option Explicit
Public Today As Date, triggerQuickPickListReload As Boolean, triggerFirstMarketSelect As Boolean
Public currentMarket As String ' best to be a public variable so can be accessed by any routine
Sub logBalance()
Dim r As Integer
r = 2
While Sheet2.Cells(r, 1) <> ""
r = r + 1
Wend
Sheet2.Cells(r, 1) = currentMarket
Sheet2.Cells(r, 2) = Worksheets("Sheet1").Range("I2").Value
End Sub
by samhayer » Wed Sep 09, 2020 11:21 am
by Captain Sensible » Wed Sep 09, 2020 11:25 am
by rluk » Wed Sep 09, 2020 11:31 am
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Columns.Count <> 16 Then Exit Sub
Application.EnableEvents = False
If Range("AD1") = "Y" Then
Refresh
Else
If Range("AJ1") = "Y" Then
QuickPickUpdate
Else
End If
End If
Application.EnableEvents = True
End Sub
Sub QuickPickUpdate()
Application.ScreenUpdating = False
Sheets("Market").Select
Range("Q2").Select
ActiveCell.FormulaR1C1 = "-4.1"
Range("AA2").Select
Application.ScreenUpdating = True
End Sub
by samhayer » Wed Sep 09, 2020 11:40 am
by Captain Sensible » Wed Sep 09, 2020 11:43 am
by samhayer » Wed Sep 09, 2020 12:10 pm
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.