Calculations in a txt field

Ice Rhino

Registered User.
Local time
Today, 23:06
Joined
Jun 30, 2000
Messages
210
I have a form that displays information from two different SQL databases. One of the fields, well actually several, has a Byte figure within them e.g. 73363456. For display purposes only I would like the txt box to change the value to display MB e.g. 69.96MB. If my calculations are correct that is 73363456 / 1024 / 1024. How would I do this?

Secondly, another field contains processor values, 2387MHz as an example. How would I get this to round it up (or Down) to the value of 2.4GHz

Any suggestions would be gratefully rec'd.

Thank you in anticipation of your prompt helpful responses
 
I am still trying ideas to solve thsi one myself. I have found that if I create a text box and in the control source place the value of

=[FreeMemory]/1024/1024

Then I get the right answer. If I try to place this expression in the original txt box however I get #Error.

Yes a workaround would be to have a number of hidden boxes (original txt boxes) and have a number of false ones that have the working calculation in place. But to me that seems a little messy and long winded

Still working on it any help gratefully rec'd
 
Ice Rhino said:
Then I get the right answer. If I try to place this expression in the original txt box however I get #Error.

You make it sound like you are trying to store a calculated value in a table by binding an expression to a textbox that you also want bound to an underlying recordset.

The textbox with the expression is NOT a workaround; it's a sensible approach.
 

Users who are viewing this thread

Back
Top Bottom