Display name value from form list in email response

Mark Elliott asked on December 13, 2016 22:30

Is there a way to get the selected name value from a form submission into the auto response email?

I know I can store the name as a delimited value in the value of the list like this:

value:name;name

That works fine in some cases but in this instance I don't want to have a delimited value like that stored in the db.

Correct Answer

Zach Perry answered on December 13, 2016 23:21

I am assuming you have a field on your form with a drop down list and that your values are something along these lines:

1; Option 1

2; Option 3

3; Option 4

The email will have the value of whatever value eventually gets stored in the database for that form. So in this case it would send out 1, 2, or 3, and you want to get the text values, correct?

The only way I can think of would be to create a custom macro and pass in the value and look up which option it is.

0 votesVote for this answer Unmark Correct answer

Recent Answers


Mark Elliott answered on December 13, 2016 23:29

Yes that is correct. A custom macro in the email response you mean?

0 votesVote for this answer Mark as a Correct answer

Zach Perry answered on December 14, 2016 04:21

Yes you can create a custom macro, and then use it in the layout of the email response.

0 votesVote for this answer Mark as a Correct answer

Roman Hutnyk answered on December 14, 2016 10:52

I'd create custom table (in case you haven't it yet) so you could populate dropdown values from it. And as Zachary recommended, use custom macro to lookup value from custom table by id.

0 votesVote for this answer Mark as a Correct answer

Mark Elliott answered on December 14, 2016 16:59

The dropdown values are being pulled from a query against the Categories table. I'll look into doing a custom macro to lookup the category name based on the ID

Thanks!

0 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.