Trying to get "0" to appear in an email
Just wondering how would I get the number "0" to appear in email...please see attached pic.
That is a summary field of cbalance dueIt is checkmarked under number format to display 2digits.
The data format specified on a layout has no effect on the value displayed elsewhere such as the body of your email--as you have discovered.
You'll need to use a calcualtion that formats your data to include trailing zeros in the cents columns.
Let ( [ N = cbalance due ; P = position ( N ; "." ; 1 ; 1 ) ]; Int ( N ) & If ( P ; Left ( Mod ( N ; 1 ) & "0" ; 3 ) ; ".00" ) )
Hi Phil...so which field do I place this formula in...I am guessing the cbalance due. The cbalancedue has this formula already:
Round (cJobTotal - cPaymentPortion;2)
Thanks for you help. -J
You could substitute Round (cJobTotal - cPaymentPortion;2) for cbalance due in the above expression provided you change the result type to text, but it can be used a calculation defined in the body box of your email--which is what I had in mind and is why the calculation refers to cbalance due. It does not need to be defined in any field.
Phil...I was scared to death to input all that just to get a "0".....it worked like a champ.
I was just wondering, is their a way to get the portal list of all invoices paid into an email? See attached pic.
It's possible if plain text with tabs between each column is acceptable. Otherwise, you would eaier generate and attach a PDF or acquire an Email Plug in that supports more sophisticated formatting.
The plain text solution:
Define a calculation field, cPortalRow, in the portal table as:
Inv # & Char ( 9 ) & Qb # & Char ( 9 ) ..... & Char ( 9 ) & Amt. Due (didn't type out entire list of fields here...)
Then, in your email body, use:
List ( PortalTableTable::cPortalRow )
Hi Phil, I tried this and it only list the first row of information....Any idea how all the rows can be listed.
I got that figured out, I had the Calc field in wrong table. It looks like I need a little formating. For the numbers to line up using Char(9) it needs to be at least 5 digits...other wise it looks pretty good. see pic.
Here is the latest link...couldn't delete the other one. -J
Ok here is another image with the functions used.
You are up against the limitations of Plain text emails. Note that the number of characters in teh values that appear too far to the left have fewer characters than those that doen't. Thus, the "tab stops" in your email browser align them one tab setting further to the left and this misaligns your data. And you can also see that your data is left justified instead of right justified.
An attached PDF, while less convenient for the recipient than including the data in the email body, will not have this limitation.
Is there a Char() for the spaces a spacebar makes?
If you look up Code in FileMaker help, you'll find the codes for any number of useful characters.
Space is returned by Char ( 32 ).
Of course you can also just put spaces between quotaion marks.
Retrieving data ...