grivers
Posts: 28
|
Posted: 04/15/2009, 1:56 AM |
|
Can anyone tell me what is wrong with this code?
If (enquiry.priority.Text = "Low") then enquiry.TextBox1.Text = DateAdd("d",60,Date())
Else If (enquiry.priority.Text = "Medium") then enquiry.TextBox1.Text = DateAdd("d",120,Date())
Else If (enquiry.priority.Text = "High") then enquiry.TextBox1.Text = DateAdd("d",240,Date())
End If
I am trying to add the specified number of days to a text field depending on the priority on a drop down.
Thanks.
|
|
|
mljonzs
Posts: 124
|
Posted: 04/15/2009, 6:59 AM |
|
I don't see an End If Statement here
_________________
What does not begin WITH God, will end in failure!
|
|
|
grivers
Posts: 28
|
Posted: 04/17/2009, 3:57 AM |
|
I have resolved with the following statement
If (enquiry.priority.Text = "Low") then enquiry.due_date.Text = DateAdd("d",120,Date()) Else
If (enquiry.priority.Text = "Medium") then enquiry.due_date.Text = DateAdd("d",60,Date()) Else
If (enquiry.priority.Text = "High") then enquiry.due_date.Text = DateAdd("d",30,Date())
|
|
|
|