Cdate

I have a form where the user enters some information, one field is a date. I have a date 04/18/1982 I'm using CDATE to convert from string to date format so it can be inserted into access.

It works fine if the field is not null. If the user leaves the field null i get page not able to display, is there any way to use CDate with a null value?

View Replies


ADVERTISEMENT

CDate

Does anyone know how to combined two select fields and convert it into date using CDate()?

I would like to make up 2 selects option in a form
select 1 is for month and select 2 is for year. when user select the desired month and year, these 2 fields will be converted into date format using CDate() but unfortunately I am having problems as CDate only recognise string and single value...

I tried to combined the 2 values using

mydate = Request.Form("month") and Request.Form("year") but alway returned an error. How do you combined these 2 values so I can get single value to be inserted into the CDate() function?

View Replies View Related

CDate/SA-Fileup

why this is giving me a 'type mismatch' error on the last line with the (CDate) when i use it with SA-Fileup and everything works fine when I am not using SA-Fileup. Checked out the SA-Fileup docs and couldn't find anything.

here it is.Code:

Set oFileUp = Server.CreateObject("SoftArtisans.FileUp")

eventStartDate = oFileUp.Form("sYear") & "-" & oFileUp.Form("sMonth") & "-" & oFileUp.Form("sDay") & " " & oFileUp.Form("sTimeHour") & ":" & oFileUp.Form("sTimeMinutes") & ":" & oFileUp.Form("sTimeSeconds")

View Replies View Related

SA-Fileup And CDate...

Can anyone tell me why this is giving me a 'type mismatch' error on the last line with the (CDate) when i use it with SA-Fileup and everything works fine when I am not using SA-Fileup. Checked out the SA-Fileup docs and couldn't find anything.

Code:

Set oFileUp = Server.CreateObject("SoftArtisans.FileUp")
eventStartDate = oFileUp.Form("sYear") & "-" & oFileUp.Form("sMonth") & "-" & oFileUp.Form("sDay") & " " & oFileUp.Form("sTimeHour") & ":" & oFileUp.Form("sTimeMinutes") & ":" & oFileUp.Form("sTimeSeconds")

eventEndDate = oFileUp.Form("eYear") & "-" & oFileUp.Form("eMonth") & "-" & oFileUp.Form("eDay") & " " & oFileUp.Form("eTimeHour") & ":" & oFileUp.Form("eTimeMinutes") & ":" & oFileUp.Form("eTimeSeconds")

ESDT = CDate(eventStartDate)

View Replies View Related

Using Cdate Function To Display Data Under Criteria

I am trying to change an existing function that currently only displays records that
fall under a criteria of

NOT(now>cdate(OTDate & ' 2:00 AM')

If I wanted to change this function to display entries that are before
6:00 pm the day before the OTDate, how could I modify this part of my
code? should is be something like this...

NOT(now>cdate((OTDate -1) & ' 6:00 PM')

View Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved