?
Solved

How to implement timespan data entry in ASP.net MVC application using  am/pm for time entry?

Posted on 2014-11-29
3
Medium Priority
?
404 Views
Last Modified: 2014-12-06
How to implement time span data entry in ASP.net MVC application using  am/pm for time entry?
Back end sql table is using time as data type.
0
Comment
Question by:Jugnoo2013
[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
3 Comments
 
LVL 21

Expert Comment

by:Craig Wagner
ID: 40472499
TimeSpan has a very specific meaning in .NET, there is a datatype for it. Are you sure that's what you're asking for? Or do you mean "date/time data entry?"
0
 

Author Comment

by:Jugnoo2013
ID: 40472817
I agree but TimeSpan is mapped to time(7) data type in sql server. It will just be used for time only calculations.
0
 
LVL 21

Accepted Solution

by:
Craig Wagner earned 1500 total points
ID: 40472887
One problem you're going to run into is that the TimeSpan type represents an interval of time, it has no concept of am/pm. If you're trying to represent a time-of-day you've picked the incorrect type. You'll probably need to use a datetime and then apply an editor mask so only the time portion shows up and is entered.
0

Featured Post

Visualize your virtual and backup environments

Create well-organized and polished visualizations of your virtual and backup environments when planning VMware vSphere, Microsoft Hyper-V or Veeam deployments. It helps you to gain better visibility and valuable business insights.

Question has a verified solution.

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

Whether you've completed a degree in computer sciences or you're a self-taught programmer, writing your first lines of code in the real world is always a challenge. Here are some of the most common pitfalls for new programmers.
The SignAloud Glove is capable of translating American Sign Language signs into text and audio.
In this fourth video of the Xpdf series, we discuss and demonstrate the PDFinfo utility, which retrieves the contents of a PDF's Info Dictionary, as well as some other information, including the page count. We show how to isolate the page count in a…
With the power of JIRA, there's an unlimited number of ways you can customize it, use it and benefit from it. With that in mind, there's bound to be things that I wasn't able to cover in this course. With this summary we'll look at some places to go…

752 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