Using Family e-mail addresses

Moderators: Moderators, Tech Support

Post Reply
John Dykema
Posts: 320
Joined: Sun Sep 28, 2003 5:37 pm
Location: First Cutlerville Christian Reformed Church
Contact:

Using Family e-mail addresses

Post by John Dykema »

I've written many custom reports but I keep getting the Yellow screen of death on one I'm modifying.
I recently started using the Family e-mail field if both parents use the same one, erasing the Profile emails. Now I have to change several custom reports that I've written. So in the report I'll need to test if the Profile e-mail is blank, then use the Family email, right?
I am able to add the Family e-mail Unlisted field to the Edit Output Fields without a problem. I can also add other fields like State to the Edit Output Fields with no problem. As soon as I add Family E-mail and Run the Query I get the Yellow death nell. Any advice?
Thanks. You've been very helpful before.

NeilZ
Posts: 10209
Joined: Wed Oct 08, 2003 1:20 am
Location: Dexter NM
Contact:

Re: Using Family e-mail addresses

Post by NeilZ »

John Dykema wrote:I've written many custom reports but I keep getting the Yellow screen of death on one I'm modifying.
I recently started using the Family e-mail field if both parents use the same one, erasing the Profile emails. Now I have to change several custom reports that I've written. So in the report I'll need to test if the Profile e-mail is blank, then use the Family email, right?
I am able to add the Family e-mail Unlisted field to the Edit Output Fields without a problem. I can also add other fields like State to the Edit Output Fields with no problem. As soon as I add Family E-mail and Run the Query I get the Yellow death nell. Any advice?
Thanks. You've been very helpful before.
John, just one additional question for information, you're writing this report under the Personal Profile Maintenance function, right ?
Neil Zampella

Using PC+ since 1999.

John Dykema
Posts: 320
Joined: Sun Sep 28, 2003 5:37 pm
Location: First Cutlerville Christian Reformed Church
Contact:

Re: Using Family e-mail addresses

Post by John Dykema »

Correct, Profiles/Other output/custom reports

Zorak
Tech Support
Tech Support
Posts: 3006
Joined: Thu May 13, 2004 9:59 am
Location: PowerChurch Software
Contact:

Re: Using Family e-mail addresses

Post by Zorak »

If you are including both family and profile e-mails, the report system will rename both "e_mail" fields to "e_mail_a" and "e_mail_b".

John Dykema
Posts: 320
Joined: Sun Sep 28, 2003 5:37 pm
Location: First Cutlerville Christian Reformed Church
Contact:

Re: Using Family e-mail addresses

Post by John Dykema »

Thanks, Zorak. Actually I don't even get that far. I've tried it both ways in that if I add just E-mail (from profiles), or just "Family E-mail" to the Edit Output Fields the query will run fine. But when I add the other email field in, the query aborts. Seems like it cant handle both email fields at the same time.
My system information is:
6/20/2016
PCPlus11
Windows 6.02 (I'm actually running Win 10 on my Lenovo laptop. I don't know what 6.02 is).

John Dykema
Posts: 320
Joined: Sun Sep 28, 2003 5:37 pm
Location: First Cutlerville Christian Reformed Church
Contact:

Re: Using Family e-mail addresses

Post by John Dykema »

I'm now good with the Yellow Screen of Death and know how to get around that. I could easily do this in two reports but I'm trying to print, in one report:
If the Family MailStmt is True then print the Family Email, ELSE If the Profile emailstmt is True then print the Profile Email. I can't get that ELSE phrase to work. I'm sure the second IIF is the culprit.
See:
IIF(Qmf_temp.e_mailstmt_b =.T.,Qmf_temp.e_mail_b, IIF( Qmf_temp.e_mailstmt_a = .T., Qmf_temp.e_mail_a, ' ')

How do I put a compound If/Else expression in one field? Please advise.
Addition logic problems exist when there is a Family email shared by the parents but the kids also have their Contribution statments emailed to their own email address. I haven't figured that one out either but I can wait for later.
Thanks for all you do.
John

Zorak
Tech Support
Tech Support
Posts: 3006
Joined: Thu May 13, 2004 9:59 am
Location: PowerChurch Software
Contact:

Re: Using Family e-mail addresses

Post by Zorak »

That "nested" IIF is formatted correctly. Otherwise, it would give you a syntax error when trying to run the report.

Something you should probably check for is that there is an e-mail address AND it is included on statements in each scenario:
IIF(e_mailstmt_b =.T. AND !EMPTY(e_mail_b),e_mail_b, IIF(e_mailstmt_a = .T. AND !EMPTY(e_mail_a),e_mail_a, ' ')

John Dykema
Posts: 320
Joined: Sun Sep 28, 2003 5:37 pm
Location: First Cutlerville Christian Reformed Church
Contact:

Re: Using Family e-mail addresses

Post by John Dykema »

Actually I was getting a syntax error in my IIF statement and that's why I asked "How do I put a compound If/Else expression in one field?" but I liked the way you phrased it too.
Is the !EMPTY test mean same as "NOT EMPTY"?

Zorak
Tech Support
Tech Support
Posts: 3006
Joined: Thu May 13, 2004 9:59 am
Location: PowerChurch Software
Contact:

Re: Using Family e-mail addresses

Post by Zorak »

Yes, it's just shorter. You can only have 254 characters in an expression, so especially once you start nesting inline ifs, it is important to use shorthand wherever possible!

Post Reply