Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Need help with a date/text problem 1

Status
Not open for further replies.

michpaus

Programmer
Oct 18, 2005
11
US
I have an existing report that pulls the date from a date/time field. Information is entered into a databse and from there the report is generated. The problem that I am having is that sometimes instead of entering the date, people copy and paste the date in and it is captured as text. I need a formula or a parameter that will pull the data whether it is a date/time type or text type on the crystal report. The field (Expiry Date) was set up as date when the crystal report was created and I would like to keep it that way. Is this doable? I am drawing a blank right now.
 
Hi,
Where ( or how) are the users entering the date ( or pasting the string)-




[profile]

To Paraphrase:"The Help you get is proportional to the Help you give.."
 
There is an online page that they can enter expiry date and other information about the part like qty and date rec'd etc. From that page the information is written to a database that stores all this info and from this databse we pull the data for the report. This is all done in real time, so once they enter info they can run the report and see what they just put in
 
It stores it as both. If they physically enter the date it stores it as date. If they copy and paste it is stored as text
 
check your field (which stores both text & date) to find out whether it is a date or text and then if it text then convert it into Date and then display it.
I mean -
have a formula as follows:

if isdate({table.field}) then {table.field} else
cdate{table.field}

then use this formula at the place where you have your date field.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top