Yeah! Thank you so much for you help. Yes that seems to be the problem and I can take it from here.
Thanks again,
Debbie
User Profile
Collapse
-
The function runs twice per record. The first time R = 42222222.222222 2 the second time R = 42222220.544461 9.
Microsoft says:
"To optimize a query, Microsoft Access will not rerun a custom function unless the value passed to it changes. If the function accepts a field as a parameter, Microsoft Access must rerun the custom function for each record because the data may change from record to record. If criteria...Leave a comment:
-
When I take out the rounding function (see below) R still equals 42222220.544461 9 when X = 95, D = 10000 and V = 0.0225
I added Q to just run the numbers instead of the variables and I get 42222222.222222 2.
[CODE=vb]Option Explicit
Public Function cfuQBD(X As Double, V As Double, D As Double) As String
'X is raw count
'V is volume
'D is dilution
Dim...Leave a comment:
-
Thanks Scott,
Hopefully it's somewhere in here. Also in the table where the data is coming from X, V and D are Single.
[CODE=vb]
Public Function cfuQBD(X As Double, V As Double, D As Double) As String
'X is raw count
'V is volume
'D is dilution
Dim R As Double 'Formated Calculated Result
Dim DR As Double 'Lowest Dilution Result
...Leave a comment:
-
Calculation Discrepancy
I have a module that contains a simple calculation:
R = (X * D) / V
All values are Double.
Using the following values:
X = 95
D = 10000
V = .0225
I get 42,222,222.22, but Access gives me 42,222,220.5444 619.
How is Access calculating this and how can I correct it?
No activity results to display
Show More
Leave a comment: