# Setting dateTime default value in Enhanced Prompt for variables

**URL:** https://www.finalbuilder.com/forums/t/setting-datetime-default-value-in-enhanced-prompt-for-variables/1929
**Category:** Discussion
**Created:** [January 17, 2012, 11:27am UTC](https://www.finalbuilder.com/forums/t/setting-datetime-default-value-in-enhanced-prompt-for-variables/1929 "2012-01-17T11:27:13Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![deleted\_user](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/deleted_user/32/937_2.png) [@deleted\_user](https://www.finalbuilder.com/forums/u/deleted_user)
#### Post date: [January 17, 2012, 11:27am UTC](https://www.finalbuilder.com/forums/t/setting-datetime-default-value-in-enhanced-prompt-for-variables/1929/1 "2012-01-17T11:27:13Z")

</div>

&nbsp;Greetings,

I have tried using the "Put current date/time into variable" action and then in the "select variables" in Enhanced prompt for variables I select a ReleaseDate project variable of type Date. I have tried using a temporary variable that is set in the "Put current date/time into variable" step as a default value for ReleaseDate but it the default value is always DateTime.Now. I have also tried to set the ReleaseDate project variable in the first step but with no success. &nbsp;How should I go about doing this?

&nbsp;

---

<div class="post-metadata">

### Author: ![stephen.ryan](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/s/f14d63/32.png) [@stephen.ryan](https://www.finalbuilder.com/forums/u/stephen.ryan)
#### Post date: [January 17, 2012, 11:13am UTC](https://www.finalbuilder.com/forums/t/setting-datetime-default-value-in-enhanced-prompt-for-variables/1929/2 "2012-01-17T11:13:11Z")

</div>

&nbsp;Hi

&nbsp;

I have attached an example project of how you can do this. You just need a variable to store the default date (make sure that the formatting is correct) and use this variable to set the default for the Enhanced Prompt for Variables action.

&nbsp;

Hope this helps.

&nbsp;

Regards,

Steve
[DateTimePromptForVariables.fbz7](https://www.finalbuilder.com/forums/uploads/default/original/2X/6/6c84c93164023ced67c0e25edfa3d13266e17c41.fbz7) (1.804 KB)

---

<div class="post-metadata">

### Author: ![deleted\_user](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/deleted_user/32/937_2.png) [@deleted\_user](https://www.finalbuilder.com/forums/u/deleted_user)
#### Post date: [January 18, 2012, 9:41am UTC](https://www.finalbuilder.com/forums/t/setting-datetime-default-value-in-enhanced-prompt-for-variables/1929/3 "2012-01-18T09:41:03Z")

</div>

Hello Stephen,   
  
 this works, I must have had the formatting incorrect… by the way what is the correct formatting?   
  
 Regards,   
 - Bjarki

---

<div class="post-metadata">

### Author: ![deleted\_user](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/deleted_user/32/937_2.png) [@deleted\_user](https://www.finalbuilder.com/forums/u/deleted_user)
#### Post date: [January 18, 2012, 10:06am UTC](https://www.finalbuilder.com/forums/t/setting-datetime-default-value-in-enhanced-prompt-for-variables/1929/4 "2012-01-18T10:06:51Z")

</div>

Ok, this only works if I use dd/mm/yyyy as datTime format in put current date/time action… Is that documented somewhere in the help?

---

<div class="post-metadata">

### Author: ![stephen.ryan](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/s/f14d63/32.png) [@stephen.ryan](https://www.finalbuilder.com/forums/u/stephen.ryan)
#### Post date: [January 19, 2012, 12:07pm UTC](https://www.finalbuilder.com/forums/t/setting-datetime-default-value-in-enhanced-prompt-for-variables/1929/5 "2012-01-19T12:07:46Z")

</div>

Hi   
  
 The format of the date being passed in will depend on the date time settings on your system. In particular the short date format on your system, which will be specified under Control Panel -\> Regional and Language Options -\> Format -\> Date.   
  
 Regards,   
 Steve
