Email template with variable in text box

I want to use a dropdown to populate a textbox with an email template. However I need to be able to use variables in the template. Ex. Hello {{customer.value}}
Default value for the text box would be {{selectTemplate.value}}

When I do this all the variables come across as code.

@nroeder
It will depend on how you structure the dropdown with data... can you share more examples/screenshots?


select * from RPv3SMSTemplate

So, is item.name the name of the customer?
If so, you can use {{selectTexttemplate.selectedItem.Name}}

no, name is just the name of template.


I'm storing the template in sql. I basically need to escape the textbox so the variable will populate.

Is the customer, the name of the user using the application or is the customer value stored somewhere else? If it is stored somewhere else then you would need to select the customer value from another dropdown somewhere in the application unless you can get both the customer and the template at the same time and then transform the data to allow for one selection for the template and the customer....

The customer is stored in the same database in another table. This is a module so I have CustomerName setup as an input. But it shows the input as text and not as code in the textbox.

I got this working like so:
I used a temp state value and populated a rich text field with some example text and added in the customerName.value in it. Then added a name in customerName text component and it worked.....

I think instead of CustomerName.value you need to use the tableproperites.selectedRow.Customer in your template....

But it's in a module and that module is in a app. the app contains the table so you have to reference it through the input. It appears the issue is related to escaping the quotes and getting the raw data. I've tried javascript to remove the quotes from the variable but that doesn't appear to work.

I think it might be similar to this issue "Value" isn't recognized as "Value" but string

I was able to solve by using a transformer to replace the text with the code for the variable.