|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
AddDate Function using a variable - for ASP site
I really need to know how to use the adddate function with a variable which takes its value from a text box that the user inputs :
Response.Write DateAdd("d", 7, Now()) Instead of the 7 - I would like to use a variable - I thought it would go something like this but does not work at all Dim variable variable = request Cint("textbox_value") Response.Write DateAdd("d", " & variable & ", Now()) I cant seem to get this to work. have you please got any ideas?? Thanks |
|
#2
|
|||
|
|||
|
May be this helps... I hope?
Code:
Dim Variable, sDisplay
Variable = request Cint("textbox_value")
sDisplay = DateAdd("d", Variable, Now())
Response.Write sDisplay
__________________
I May Have Misinterpret U'r Post Correct Me If I Am Wrong......// Enjoy Coding........................../// zak2zak |
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > ASP Programming > AddDate Function using a variable - for ASP site |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|