Automatically Calculate

M

Mavis

Hi All,

I got a form with 3 fields (Claim value, Exchange rate, USD). The user will
enter the claim value and exchange rate. How can i got the USD Automatically
Calculate when the user had enter both the field?

I am very new with access, this is my first project. Please guide me.

Thanks in advnace.
 
M

Mavis

Hi all,

More information:

I had tried to enter the below code in the control source.

[USDConversion]=[ClaimedAmount]*[ROE]
But the field show me "error"

please help.
 
A

Allen Browne

Remove the USD field from your query.

Instead, create a query, and type this into the Field row in query design:
USD: [Claim value] * [Exchange rate]
Then use the query anywhere you wish (e.g. as the Record Source for your
form or report.)

More information in this article:
Calculated fields
at:
http://allenbrowne.com/casu-14.html
 
G

Graham Mandeno

Hi Mavis

The calculated field should not be stored. Base your form on a query
instead of on the table. Base the query on your table and add all the
relevant fields as required by the form. Then add a calculated field:

USD: [Claim value] * [Exchange rate]

That way, whenever someone changes either of the source values in the
record, the USD value will be recalculated automatically. Otherwise you
would need to recalculate and re-store it, and you would always run the risk
of it getting out of sync.
 
M

Mavis

Hi,

I am really very new to access. can you teach me the step how can i do the
below instruction?


Thanks



Graham Mandeno said:
Hi Mavis

The calculated field should not be stored. Base your form on a query
instead of on the table. Base the query on your table and add all the
relevant fields as required by the form. Then add a calculated field:

USD: [Claim value] * [Exchange rate]

That way, whenever someone changes either of the source values in the
record, the USD value will be recalculated automatically. Otherwise you
would need to recalculate and re-store it, and you would always run the risk
of it getting out of sync.

--
Good Luck :)

Graham Mandeno [Access MVP]
Auckland, New Zealand

Mavis said:
Hi All,

I got a form with 3 fields (Claim value, Exchange rate, USD). The user
will
enter the claim value and exchange rate. How can i got the USD
Automatically
Calculate when the user had enter both the field?

I am very new with access, this is my first project. Please guide me.

Thanks in advnace.
 
G

Graham Mandeno

Hi Mavis

Which version of Access? I'll assume 2003 as it's most common, but the
procedure for 2007 is similar.

1. From the Queries page of the database window, double-click "Create query
in design view"

2. Find your table in the "Show table" list and double-click it to add it to
your query design. Then click "Close"

3. Double-click on the "*" in the small window showing the table fields.
This will add "YourTable.*" to the query grid.

4. In the next cell of the query grid, type the following:
USD: [Claim value] * [Exchange rate]

5. Click on the View button (left of the toolbar) to view the query results.
You should see all the fields from your table and, at the right-hand side,
an extra column with the calculated USD value.

6. Close your query and save it with a sensible name.

7. Open your form in design view and make sure the Properties window is
displayed (View>Properties)

8. At the top of the list of properties, change the RecordSource from the
name of your table to the name of the query you have just created.

9. Create a textbox (or select the one you have already created) and change
its ControlSource to "USD".

--
Good Luck :)

Graham Mandeno [Access MVP]
Auckland, New Zealand



Mavis said:
Hi,

I am really very new to access. can you teach me the step how can i do
the
below instruction?


Thanks



Graham Mandeno said:
Hi Mavis

The calculated field should not be stored. Base your form on a query
instead of on the table. Base the query on your table and add all the
relevant fields as required by the form. Then add a calculated field:

USD: [Claim value] * [Exchange rate]

That way, whenever someone changes either of the source values in the
record, the USD value will be recalculated automatically. Otherwise you
would need to recalculate and re-store it, and you would always run the
risk
of it getting out of sync.

--
Good Luck :)

Graham Mandeno [Access MVP]
Auckland, New Zealand

Mavis said:
Hi All,

I got a form with 3 fields (Claim value, Exchange rate, USD). The user
will
enter the claim value and exchange rate. How can i got the USD
Automatically
Calculate when the user had enter both the field?

I am very new with access, this is my first project. Please guide me.

Thanks in advnace.
 
M

Mavis

Hi,

I am using Access 2007 but i cannot find the RecordSource.

Thanks



Graham Mandeno said:
Hi Mavis

Which version of Access? I'll assume 2003 as it's most common, but the
procedure for 2007 is similar.

1. From the Queries page of the database window, double-click "Create query
in design view"

2. Find your table in the "Show table" list and double-click it to add it to
your query design. Then click "Close"

3. Double-click on the "*" in the small window showing the table fields.
This will add "YourTable.*" to the query grid.

4. In the next cell of the query grid, type the following:
USD: [Claim value] * [Exchange rate]

5. Click on the View button (left of the toolbar) to view the query results.
You should see all the fields from your table and, at the right-hand side,
an extra column with the calculated USD value.

6. Close your query and save it with a sensible name.

7. Open your form in design view and make sure the Properties window is
displayed (View>Properties)

8. At the top of the list of properties, change the RecordSource from the
name of your table to the name of the query you have just created.

9. Create a textbox (or select the one you have already created) and change
its ControlSource to "USD".

--
Good Luck :)

Graham Mandeno [Access MVP]
Auckland, New Zealand



Mavis said:
Hi,

I am really very new to access. can you teach me the step how can i do
the
below instruction?


Thanks



Graham Mandeno said:
Hi Mavis

The calculated field should not be stored. Base your form on a query
instead of on the table. Base the query on your table and add all the
relevant fields as required by the form. Then add a calculated field:

USD: [Claim value] * [Exchange rate]

That way, whenever someone changes either of the source values in the
record, the USD value will be recalculated automatically. Otherwise you
would need to recalculate and re-store it, and you would always run the
risk
of it getting out of sync.

--
Good Luck :)

Graham Mandeno [Access MVP]
Auckland, New Zealand

Hi All,

I got a form with 3 fields (Claim value, Exchange rate, USD). The user
will
enter the claim value and exchange rate. How can i got the USD
Automatically
Calculate when the user had enter both the field?

I am very new with access, this is my first project. Please guide me.

Thanks in advnace.
 
G

Graham Mandeno

Hi Mavis

In Access 2007 the menus are a little different.

1. With the form in design view, EITHER click the "Property Sheet" button on
the right of the Design ribbon OR press Alt+Enter. The Property Sheet
should then be visible.

2. Select the form by clicking the grey square to the left of the top ruler
OR by selecting "Form" in the dropdown list at the top of the property
sheet.

3. Select either the Data tab or the All tab in the property sheet.

4. You should now see "Record Source" at the top of the properties list.

--
Good Luck :)

Graham Mandeno [Access MVP]
Auckland, New Zealand

Mavis said:
Hi,

I am using Access 2007 but i cannot find the RecordSource.

Thanks



Graham Mandeno said:
Hi Mavis

Which version of Access? I'll assume 2003 as it's most common, but the
procedure for 2007 is similar.

1. From the Queries page of the database window, double-click "Create
query
in design view"

2. Find your table in the "Show table" list and double-click it to add it
to
your query design. Then click "Close"

3. Double-click on the "*" in the small window showing the table fields.
This will add "YourTable.*" to the query grid.

4. In the next cell of the query grid, type the following:
USD: [Claim value] * [Exchange rate]

5. Click on the View button (left of the toolbar) to view the query
results.
You should see all the fields from your table and, at the right-hand
side,
an extra column with the calculated USD value.

6. Close your query and save it with a sensible name.

7. Open your form in design view and make sure the Properties window is
displayed (View>Properties)

8. At the top of the list of properties, change the RecordSource from the
name of your table to the name of the query you have just created.

9. Create a textbox (or select the one you have already created) and
change
its ControlSource to "USD".

--
Good Luck :)

Graham Mandeno [Access MVP]
Auckland, New Zealand



Mavis said:
Hi,

I am really very new to access. can you teach me the step how can i do
the
below instruction?


Thanks



:

Hi Mavis

The calculated field should not be stored. Base your form on a query
instead of on the table. Base the query on your table and add all the
relevant fields as required by the form. Then add a calculated field:

USD: [Claim value] * [Exchange rate]

That way, whenever someone changes either of the source values in the
record, the USD value will be recalculated automatically. Otherwise
you
would need to recalculate and re-store it, and you would always run
the
risk
of it getting out of sync.

--
Good Luck :)

Graham Mandeno [Access MVP]
Auckland, New Zealand

Hi All,

I got a form with 3 fields (Claim value, Exchange rate, USD). The
user
will
enter the claim value and exchange rate. How can i got the USD
Automatically
Calculate when the user had enter both the field?

I am very new with access, this is my first project. Please guide
me.

Thanks in advnace.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top