# Email action, set smpt host port from variable

**URL:** <https://www.finalbuilder.com/forums/t/email-action-set-smpt-host-port-from-variable/4209>\
**Category:** Feature Requests\
**Created:** [April 10, 2014, 8:24am UTC](https://www.finalbuilder.com/forums/t/email-action-set-smpt-host-port-from-variable/4209 "2014-04-10T08:24:00Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![jom\_widex](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/j/4af34b/32.png) [@jom\_widex](https://www.finalbuilder.com/forums/u/jom_widex)\
**Post date:** [April 10, 2014, 8:24am UTC](https://www.finalbuilder.com/forums/t/email-action-set-smpt-host-port-from-variable/4209/1 "2014-04-10T08:24:00Z")

</div>

I would like it to be possible to set the smtp&nbsp;port from a variable in the email action.

/O2m

&nbsp;

---

<div class="post-metadata">

**Author:** ![Vincent](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/vincent/32/938_2.png) [@Vincent](https://www.finalbuilder.com/forums/u/Vincent)\
**Post date:** [April 11, 2014, 12:39pm UTC](https://www.finalbuilder.com/forums/t/email-action-set-smpt-host-port-from-variable/4209/2 "2014-04-11T12:39:26Z")

</div>

You can do it through scripting, in the BeforeAction script event (javascript)   
  
 [code]Action.Port = FBVariables.PORT [/code]

---

<div class="post-metadata">

**Author:** ![jom\_widex](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/j/4af34b/32.png) [@jom\_widex](https://www.finalbuilder.com/forums/u/jom_widex)\
**Post date:** [April 11, 2014, 4:31am UTC](https://www.finalbuilder.com/forums/t/email-action-set-smpt-host-port-from-variable/4209/3 "2014-04-11T04:31:08Z")

</div>

Thanks for the trick.

It will come in handy in many other actions.

/O2m
