[AccessD] Problem with Date type variable

Geldart, Robert RGeldart at detma.org
Tue Mar 25 08:47:17 CST 2003


Barbara,
 
Can you show an example of how the date should look on the text file, and if
possible how it looks on the record whereit appears as 12:00?
 
I'm assuming it's simply a formatting problem. However, if it's possible
that some dates are not in proper format on the text file, make sure you're
prepared for them.
1. Import the date as a text and then deal with it. Try Trim(ImportString)
to strip spaces
2. Make sure it's not a null. Try NZ(ImportString,"_")
3. If you are only getting a default time (with no date), it may be an empty
string. Try NZ(Trim(ImportString),"_")

-----Original Message-----
From: Barbara Ryan [mailto:BarbaraRyan at cox.net]
Sent: Tuesday, March 25, 2003 9:02 AM
To: accessd at databaseadvisors.com
Subject: Re: [AccessD] Problem with Date type variable


I am importing data from a text file ---- only if the "date" in this import
file is populated (i.e., NOT blank/spaces), then the import date is moved to
my date variable ("dtDate").  I then write the contents of dtDate (along
with other data) to a table, which is then printed on a report.  Should I be
checking "If dtDate <> 12:00:00 AM, then write contents of dtDate to table
date?"
 
Thanks,
Barb

----- Original Message ----- 
From: Jim DeMarco <mailto:Jdemarco at hshhp.org>  
To: accessd at databaseadvisors.com <mailto:accessd at databaseadvisors.com>  
Sent: Tuesday, March 25, 2003 8:33 AM
Subject: RE: [AccessD] Problem with Date type variable

That's the zero value for a Date datatype.  Any variable of this type has
this value until you fill it with a value.

Thanks, 

Jim DeMarco 

-----Original Message-----
From: Barbara Ryan [mailto:BarbaraRyan at cox.net]
Sent: Tuesday, March 25, 2003 7:52 AM
To: Access List
Subject: [AccessD] Problem with Date type variable


I am encountering a problem with date type variables in Access 97.  When I
create a date type variable (e.g., "Dim dtDate as Date") , the variable has
a default value of 12:00:00 AM.  I don't remember this happening before.
 
I recently did a "cleanup" on my PC, removing software I no longer use.
Could I have removed a needed driver(s)?  I ask that question because I am
also having a problem with my printer (HP IIP Plus) not printing lines on
reports (which it was doing fine last week).  
 
Any thoughts?
 
Thanks,
Barb Ryan



****************************************************************************
*******
"This electronic message is intended to be for the use only of the named
recipient, and may contain information from HealthSource/Hudson Health Plan
(HS/HHP) that is confidential or privileged. If you are not the intended
recipient, you are hereby notified that any disclosure, copying,
distribution or use of the contents of this message is strictly prohibited.
If you have received this message in error or are not the named recipient,
please notify us immediately, either by contacting the sender at the
electronic mail address noted above or calling HS/HHP at (914) 631-1611. If
you are not the intended recipient, please do not forward this email to
anyone, and delete and destroy all copies of this message. Thank You".
****************************************************************************
*******




  _____  




_______________________________________________
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com




More information about the AccessD mailing list