Forums: [SOLVED] Including specific field values in email - Forums

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • This topic is locked

[SOLVED] Including specific field values in email Rate Topic: -----

#1 User is offline   swiersman 

  • Advanced Member
  • PipPipPip
  • Group: Members
  • Posts: 57
  • Joined: 14-July 06

Posted 25 May 2018 - 05:17 PM

HI,

I know this must be simple, but how do you include specific field values in the body of an email?

I see templates for sending a simple email, and for sending all fields that have been updated, but none for specific fields I would like to have sent.


Thanks ahead of time for any assistance...
0

#2 User is offline   admin 

  • Administrator
  • PipPipPip
  • Group: Admin
  • Posts: 15999
  • Joined: 03-February 03

Posted 25 May 2018 - 09:24 PM

If you talking about events like BeforeEdit or AfterEdit you can access the value of any field as value["FieldName"]. So just compose your message inserting field values where needed.

More info:
https://xlinesoft.co...ord_updated.htm
https://xlinesoft.co...il_function.htm
Best regards,
Sergey Kornilov
0

#3 User is offline   jadach 

  • Advanced Member
  • PipPipPip
  • Group: Members
  • Posts: 421
  • Joined: 26-April 08

Posted 27 May 2018 - 06:18 PM

View Postswiersman, on 25 May 2018 - 01:17 PM, said:

HI,

I know this must be simple, but how do you include specific field values in the body of an email?

I see templates for sending a simple email, and for sending all fields that have been updated, but none for specific fields I would like to have sent.


Thanks ahead of time for any assistance...



I think what you are looking for is the syntax to add field data into the body of the email. See here where FirstName and LastName are fields in your database:
string msg = "Greetings "+values["FirstName"].ToString()+" "+values["LastName"].ToString()+"";

-jerry
0

Page 1 of 1
  • You cannot start a new topic
  • This topic is locked