I have a problem with a notes app that based on selections, will send an automatic email. The problem is that it is not picking up the ReturnAddress. This is based on a user selection. Here is some of the code…I would greatly appreciate any help with the code. (V3 is the selected address.
ReturnAddress := @If(
v3 = "Customerxyz1";
"Address1" + @NewLine + "road1" + @NewLine + "city state1";
v3 = "Customerxyz2";
"Address2" + @NewLine + "road2" + @NewLine + "city state2";
" Please contact us for confirmation ");
Subject: get the quotation marks off of the field names
Subject: RE: @IF Problem
Are you getting the “Please contact us…” every time or the names of the variables themselves (per Bill’s response) which would look like:
Address1
road1
city state 1
Subject: RE: @IF Problem
I get the “Please contact us…” and nothing about the address.
Subject: RE: @IF Problem
OK. So if I understand correctly the user picks a customer on the form and then this agent executes to get the return address.Sorry for all the questions, but there are a lot of things that could be happening depending on how the form and agent are designed. For example, this code in a button on the form that the user presses would work differently than a scheduled agent that processes the forms on a schedule.
From your response it sounds like the formula is not getting the proper value for V3 to match (which is I think where Bill is headed). Can you set up a dummy customer with the name of “A” and put that into your code, select the customer “A”, and see if the rest of the formula works? This will eliminate case, spelling errors, etc. and validate that the rest of the code works.
Subject: RE: @IF Problem
First - thanks for your help.
I added the customer A, and it did not print
Subject: Then put @Prompt([OK]; “V3”; V3); before your formula to find out what V3 is.
Subject: RE: Then put @Prompt([OK]; “V3”; V3); before your formula to find out what V3 is.
I added the @prompt line, but I still do not get the address
Subject: What did you get prompted with??? i.e. What was the value of V3?
Subject: RE: What did you get prompted with??? i.e. What was the value of V3?
I was prompted with the complete list of possible addresses, as it has always done