Solved

Access 2103 Web App: How to create a data macro calculation to update a field

Posted on 2014-09-06
2
827 Views
Last Modified: 2014-09-06
Quick & simple; have to fields and want the third to calculate and then update a third field.  The key if I'm asking right is the 3rd field exists in the table, I just want it "filled in" based on values of the other two fields.

Advice to date is use a data macro.  Could use a little more step by step feedback...
0
Comment
Question by:VirtualKansas
2 Comments
 
LVL 84

Accepted Solution

by:
Scott McDaniel (Microsoft Access MVP - EE MVE ) earned 500 total points
ID: 40307545
Better advice would be to NOT store calculated data, and instead use a query to provide that calculation "on the fly" - something like:

SELECT Field1, Field2, Field1 + Field2 AS [TotalField] FROM YourTable
0
 

Author Closing Comment

by:VirtualKansas
ID: 40307761
Exactly how we do it on desktop.  ...and to add luster to this advice, since we're (all) new to the app. db, we experimented with macros and found our limits in that testing a macro to update the actual field value was inadvertently creating new blank records.

In the interim, to display in the web view we simply created a new control that's source is the two fields for the calculation and disabled it in format.  

The calculation is done in the view and presented in the view in a "read only" field.  Now we get to exercise creating queries in the app. but short term we've got the result for the app. view and seems like the proper method.

What would be super helpful, since we have many views that will benefit from this calculated field, would be to simply copy & paste to the views, vs. having to edit each view once we conquer a little bugger like this one.  For now, thank you for some good validation and reminder of the basics...
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Entering time in Microsoft Access can be difficult. An input mask often bothers users more than helping them and won't catch all typing errors. This article shows how to create a textbox for 24-hour time input with full validation politely catching …
Never store passwords in plain text or just their hash: it seems a no-brainier, but there are still plenty of people doing that. I present the why and how on this subject, offering my own real life solution that you can implement right away, bringin…
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
In Microsoft Access, learn how to “cascade” or have the displayed data of one combo control depend upon what’s entered in another. Base the dependent combo on a query for its row source: Add a reference to the first combo on the form as criteria i…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now