Cheers that helped a lot I got it working using:

Dim var10 As Decimal

Dim var11 As Decimal

'Get 5% of the house price as a decimal number

var10 = (txtPriceOfProperty.Text / 100) * 5

'Get the deposit as a decimal

var11 = txtDeposit.Text

'Check the depositis grater then the asking amount

If (var11 >= var10) Then

CheckDepostit = True

Else

CheckDepostit = False

End If

Thank you for your help

Cheers

Rabid Lemming

Perhaps the problem is that the value is text, not numeric. Try converting it first. In VB you could use CDbl().

Also try showing the numbers before and after the calculation (debug.print or msgbox or whatver works to show them on the screen) to see what is going on.

It is also possible that when dividing by 100 it is thinking "this is a whole number, so the answer should be a whole number".

Try this:

MinDeposit = cdbl(txtPriceOfProperty.Text) * 0.05

if (Deposit >= MinDeposit) then

...

end if

Let's know how you get on

]]>I really hate maths lol, ok heres my problem

I have a variable know as PriceOfProperty

I have another variable known as Deposit

Both variables can be any number as they are set by a user input

I need to ensure that what ever the PriceOfProperty the Deposit is at least 5% of that value

It has to be in the format of an if statement like so:

If the Deposit value is 5 % of PriceOfProperty value then true

Only its actual syntax is in this format:

If (txtPriceOfProperty.Text / 100) * 5 > . Then

Only that sum doesnt work as that now how you work it out

Any help would be appreciated

Cheers

Rabid Lemming