|
By:
Was just about to post that.
|
|
By:
I lay horses.
My fav is if(cell="w",((cell-1)*-100),100). Simple but effective, providing the fookin horse gets beaten. |
|
By:
That if statement does nothing?^^
|
|
By:
Ovalman,
it works for me, but I'm not gonna tell you which ones to lay ![]() |
|
By:
I don't know excel but if statements should have conditions
If bfSP = 0 Then bfBakWin = 0: Exit Function If Pos = 1 Then Yours has no conditions ![]() |
|
By:
The = is to test equals, as it's basic.
The : AFAIK joins up everything to the right of his Then, so both are done. In english: "set as zero and then exit". Condition THAT! *drops mic and walks off* ![]() |
|
By:
No experience of Excel
What does if(cell="w",((cell-1)*-100),100) mean. |
|
By:
Should have been:
Function bfBakWin(Pos, bfSP, Optional IDref As String) bfBakWin = XUstk(-1) If bfSP = 0 Then bfBakWin = 0: Exit Function If Pos = 1 Then bfBakWin = XUstk(Round(((bfSP - 1) * RedFact(IDref)) * CommNet, 2)) End If End Function Where Pos = finishing position and bfSP = BF starting price Idref is the unique race ID reference RedFact checks Idref against a table of races subject to r4 deductions and dead heats and returns a reduction factor (1 if their are none) CommNet returns the result net of commission. Ustk = returns the above calculation * your unit stake I shall now repair to General Betting for a similarly lukewarm response. |
|
By:
Ovalman.
18 Feb 17 19:05 Joined: 29 Nov 02 | Topic/replies: 14,009 | Blogger: Ovalman.'s blog No experience of Excel What does if(cell="w",((cell-1)*-100),100) mean. I keep a spreadsheet to capture my history. Each row shows whether the selection won (w) or lost (blank). The logic in the formula looks at the cell containing w or blank, and then takes the price I got for my lay bet, and calculates whether I won money or lost money and how much. Of course I could just look at my Betfair P&L, but being a former accountant, I like to have some checks and balances. Betfair have been known to make the occasional error. |
|
By:
I'm developing a few Android apps atm so these things interest me. I always meant to learn excel but it's on the back burner as I get to grips with Java.
If you learn one language, all the rest seem to fall into place imo. |
|
By:
Ovalman, GL with that.
Many, many years ago I bought a home computer and was learning to write in BASIC. I wrote a dice game programme with automatic scoring for each player for the kids. I wrote little modules and kept testing them. I then put them all together and the fookin machine got over excited and scrambled everything!! It had only got 16k of RAM and I think I made its head hurt. Never again. ![]() ![]() |
|
By:
I've got a question time function:
if x=1, blame Brexit, Trump, Racism, Hitler, Fascism, Islamophobia and Bankers = round of applause. End function |
|
By:
That's how I got started, bought myself a ZX81 and there was nothing else to do on it but learn to program. Upgraded to a ZX Spectrum but then my willy got bigger and women were more appealing than computers
![]() Tried several times in the past to get back into it but everything seemed so alien. Object Orientated Programming talked about building feckin houses FFS and you had to use Notepad++ and a compiler to run things. Not a wonder I struggled. I stuck with it tho, kept trying and then done a free course on Udacity where everything seems to have clicked. I'm working on a business idea atm which I think would sell, there's nothing on the app store that has been addressed so I think it has a unique selling point. The great thing is the line of business is not a niche so I'd have many potential customers. I've a basic working app atm but not ready for the app store. I've other ideas but I don't think your ever too old to learn. I'm 48 and still try, that's why I questioned the if statement ![]() |