I realize this is old, but for the person out there that is googling for the answer... this is what I used for the process:
Note, I want to make this a tad bit more clear by explaining this:This value equates to an integer that indiciates how many times num2 can be taken out of num1.
'Returns the remainder of the division: num1 / num2.
Public Function Remainder(num1 As Double, num2 As Double) As Double
If (num1 / num2) = Int(num1 / num2) Then 'Check to see if the result is an integer by comparing the original result to a rounded-down result.
'Since the results are equal, the result is a whole number
Remainder = 0 'Return 0 since there is no remainder.
Dim tmp As Double
tmp = num1 - Int(num1 / num2) * num2 'Remove the integer portion of the number by subtracting it from num1.
Remainder = tmp / num2 'Return the remainder portion.
So, when we use this to find the remainder, we were actually calculating the numerator of our return value.
The following subtracts the evenly divisible portion of the division from num1.
Thus, that is how we are left with a decimal remainder!
tmp = num1 - Int(num1 / num2) * num2