Home |
Search |
Today's Posts |
#1
|
|||
|
|||
Form Field Calculations
I'm trying to do some fancy stuff in a form field set as a calculation,
but I can't get Word to cooperate properly. I'd like to keep out of using macros, as I absolutely HATE VB and since these documents will be traveling to multiple people, I don't appreciate Word popping up dialog boxes every time the file is opened to let them know there are potentially dangerous things in the macros. Here's what I'm trying to do: I have a field called LoanAmount that is formatted as a number, with Calculate on Exit checked. I also have fields called AppraisedValue and PurchasePrice which are also formatted exactly like LoanAmount. Finally, there is a field called LTV which is a calculation field that looks like this: =(LoanAmount / AppraisedValue) * 100 The problem with this calculation is that the LTV is actually calculated based on the lesser of either the AppraisedValue or the PurchasePrice field. It's easy enough to add min(AppraisedValue, PurchasePrice), BUT, PurchasePrice is sometimes blank or zero, and as such, the calcuation will always return that figure. What I need it to do is condition for which value is lesser, but still greater than zero, then plug that into the function. Can anyone help? Thanks, Adam |
#2
|
|||
|
|||
Hi Adam,
Probably, you can use an IF field (bookmarked or nested in a SET field to generate a bookmark - you may need to try various combinations) to do the test. Then pick up THAT result for the calculation you're displaying. VERY rough example: { SET CheckVal { IF { PurchasePrice} 0 "True value" "False Value" } } CheckVal is the bookmark name you'd use in the later field. I have a field called LoanAmount that is formatted as a number, with Calculate on Exit checked. I also have fields called AppraisedValue and PurchasePrice which are also formatted exactly like LoanAmount. Finally, there is a field called LTV which is a calculation field that looks like this: =(LoanAmount / AppraisedValue) * 100 The problem with this calculation is that the LTV is actually calculated based on the lesser of either the AppraisedValue or the PurchasePrice field. It's easy enough to add min(AppraisedValue, PurchasePrice), BUT, PurchasePrice is sometimes blank or zero, and as such, the calcuation will always return that figure. What I need it to do is condition for which value is lesser, but still greater than zero, then plug that into the function. Cindy Meister INTER-Solutions, Switzerland http://homepage.swissonline.ch/cindymeister (last update Jun 8 2004) http://www.word.mvps.org This reply is posted in the Newsgroup; please post any follow question or reply in the newsgroup and not by e-mail :-) |
Reply |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
How can a user change the default date in a form field? | Tables | |||
Form Field Formatting | Microsoft Word Help | |||
Enter data in 1 text form field & have multiple locations fill | Microsoft Word Help | |||
Text Form Field Ref in Footer Won't Update on Screen | Microsoft Word Help | |||
Form Field Automation | Microsoft Word Help |