Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Visual Studio.NET / General / November 2004

Tip: Looking for answers? Try searching our database.

Entering a timespan value of 24:00 in property pane

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Jos - 25 Nov 2004 07:19 GMT
I have a custom control with a property of type TimeSpan.

When I enter a value of 24:00:00 in the property pane I get an "Improper
property value" error.

How do I enter this value?
And how do I enter a value greater than 24 hours?

Thanks,

Jos
Philip Taylor - 25 Nov 2004 20:40 GMT
>I have a custom control with a property of type TimeSpan.
>
[quoted text clipped - 7 lines]
>
> Jos

The error is correct, as the maximum value of a 24 hour clock is 23:59:59.
One second beyond this value is 00:00:00.
Beyond this time, you would have to maintain a separate day counter.

If you want to a general purpose timer for any number of hours, then you
would have to implement your own property.
Jos - 26 Nov 2004 07:41 GMT
> >I have a custom control with a property of type TimeSpan.
> >
[quoted text clipped - 14 lines]
> If you want to a general purpose timer for any number of hours, then you
> would have to implement your own property.

It's strange that these values can't be entered, since
the TimeSpan object itself is not limited to 24 hours.

Jos
Jos Branders - 27 Nov 2004 12:48 GMT
>>> I have a custom control with a property of type TimeSpan.
>>>
[quoted text clipped - 19 lines]
>
> Jos

OK, I found it, it's a dot between the days and the hours:

1.00:00:00 is 24 hours
1.12:00:00 is 36 hours
3.00:00:00 is 3 days
etc.

Signature

Jos


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.