Working w/ data in repeating section/table

R

RDB

I hope this makes sense...

I am pulling three columns of data from a SQL database. I would like to add
a fourth column to this table with a submit button so that each row has its
own submit button. I would like for an e-mail to generate with only the data
from that row when the submit button is hit, preferably in the body of the
message. If that's not possible, I'd like to be able to pull a field from
that row and put it in the subject line.

How can I do something like this? Or is it possible I may be asking a bit
much?
 
S

S.Y.M. Wong-A-Ton

While your question is not entirely clear to me, I'll give it a go...

It sounds as though you have a repeating table displaying data from a table
within SQL Server. Correct? You'd like to add a fourth column to this
repeating table. The column should contain a button that will send an email
with data from the current row only. Still good? If so, yes, this can be
done, but you'll have to do a bit of coding.

Add a field to the Main DOM of your form to save the currently selected row
in (use an ID or something to identify this row). Add a rule to the button
that will set the value of this field to the currently selected ID (use the
current() function in the formula when doing this). Do the same (previous 2
steps) for all the other fields that must be included in the email. Then in
code retrieve the values of all the fields of the currently selected row and
use an email adapter to generate an email, set subject and intro text, and
send it to the required recipient(s). Search this newsgroup on "email
adapter" to find samples on how this can be done.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top