?
Solved

TcxDateTime edit field does not save time to SQL, only '12:00:00 PM' after the date

Posted on 2014-04-14
4
Medium Priority
?
401 Views
Last Modified: 2014-05-22
I have several TcxDateTime fields, the properties are set to Save Time and Show Time yet the Post only saves the date and time shows '12:00:00 PM'.  I have saved other dates as well but had to set the date = Now;  
Thanks for your help :)
0
Comment
Question by:Bianca
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 27

Expert Comment

by:Sinisa Vuk
ID: 40000928
This is common. If you want to show date only then set DisplayFormat property.
Something like:
TcxDateTime(data.FieldByName('mydate')).Displayformat := 'yyyy.mm.dd';

Open in new window

maybe there is property to set if date or time will be shown. What kind of field is this field in database?
0
 
LVL 38

Accepted Solution

by:
Geert Gruwez earned 2000 total points
ID: 40004596
it depends on how you save it to the database
saving is as important as loading

how are you loading and saving the datetime value ?
0
 

Author Comment

by:Bianca
ID: 40030583
I am using qry.Edit then qry.Post
0
 
LVL 27

Expert Comment

by:Sinisa Vuk
ID: 40030677
You want to save date or date+time?
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…
In this video, Percona Solutions Engineer Barrett Chambers discusses some of the basic syntax differences between MySQL and MongoDB. To learn more check out our webinar on MongoDB administration for MySQL DBA: https://www.percona.com/resources/we…
Suggested Courses

764 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question