Time trigger
I've developed a spreadsheet which I'd like to adapt to auto trade. I came up with a macro which would cancel all bets after x seconds of in-play time. This seemed to work OK with manual testing, but as soon as I connect to BetAngel it doesn't fire at all. Any ideas why this should be - or is there a time trigger example anywhere else that I could use? My VBA knowledge is limited and mostly acquired through Googling. Any suggestions would be much appreciated.
Be careful how you use the countdown timer.
Excel stores the time as a decimal fraction so 00:00:01 for one second is actually 0.0000115741. But as soon as the countdown timer displays a negative value (-00:00:01) then there is no decimal equivalent and the value is stored in the cell as text.
Therefore, if you are relying on the countdown timer having a decimal fraction equivalent then you need to strip the negative symbol, convert to a true time format then work with the decimal fraction.
See here for a quick overview of the decimal fraction time value - http://support.microsoft.com/kb/214094
Excel stores the time as a decimal fraction so 00:00:01 for one second is actually 0.0000115741. But as soon as the countdown timer displays a negative value (-00:00:01) then there is no decimal equivalent and the value is stored in the cell as text.
Therefore, if you are relying on the countdown timer having a decimal fraction equivalent then you need to strip the negative symbol, convert to a true time format then work with the decimal fraction.
See here for a quick overview of the decimal fraction time value - http://support.microsoft.com/kb/214094
You can't multiply text by minus 1.
You need to strip out the negative symbol and format as time.
I use this formula to get an Excel decimal fraction from the countdown cell during in-play:
=TIMEVALUE(RIGHT(F4,8))
And format the cell as a number to 8 decimal places.
You need to strip out the negative symbol and format as time.
I use this formula to get an Excel decimal fraction from the countdown cell during in-play:
=TIMEVALUE(RIGHT(F4,8))
And format the cell as a number to 8 decimal places.
Hi, I have some problems with my macro that should save in cell time of last market suspension - sometimes catches that time sometimes doesnt. It's a pity that BetAngel doesn't provide neither Last Suspension Time reference to excel cell nor excel instruction such as "DELAY" that could postpone trigger firing. Somebody could help with reliable action-delaying macro?