# How do I notify team members of a potential action to-do if they are not assigned to the action?

**URL:** <https://discuss.workflowgen.com/t/how-do-i-notify-team-members-of-a-potential-action-to-do-if-they-are-not-assigned-to-the-action/383>\
**Category:** Process Design\
**Created:** [January 28, 2012, 3:10am UTC](https://discuss.workflowgen.com/t/how-do-i-notify-team-members-of-a-potential-action-to-do-if-they-are-not-assigned-to-the-action/383 "2012-01-28T03:10:20Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![eddy.daouk](https://yyz2.discourse-cdn.com/flex030/user_avatar/discuss.workflowgen.com/eddy.daouk/32/672_2.png) [@eddy.daouk](https://discuss.workflowgen.com/u/eddy.daouk)\
**Post date:** [November 26, 2020, 12:16am UTC](https://discuss.workflowgen.com/t/how-do-i-notify-team-members-of-a-potential-action-to-do-if-they-are-not-assigned-to-the-action/383/3 "2020-11-26T00:16:41Z")

</div>

Hi @marinam,

You can use a query similar to the following post to retrieve the Manager’s email:

> [@How to Retrieve First name and Last name of Manager?](https://discuss.workflowgen.com/t/how-to-retrieve-first-name-and-last-name-of-manager/895/4):
>
> Hi David, You can use the following code as an example : string lastname; string firstname; string connectionString = System.Configuration.ConfigurationManager.ConnectionStrings["MainDbSource"].ToString(); string queryString = "SELECT [LASTNAME],[FIRSTNAME] FROM [USERS] WHERE USERNAME = '" + USERNAME + "'"; using(System.Data.SqlClient.SqlConnection sqlConnection = new System.Data.SqlClient.SqlConnection(connectionString)) { System.Data.SqlClient.SqlCommand command =…

Instead of `SELECT [LASTNAME],[FIRSTNAME]` put `SELECT [EMAIL]`

Eddy.

---

_[View the full topic](https://discuss.workflowgen.com/t/how-do-i-notify-team-members-of-a-potential-action-to-do-if-they-are-not-assigned-to-the-action/383)._
