Results 1 to 2 of 2

Thread: [RESOLVED] Time period NumericUpDown type control?

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Apr 2007
    Location
    cobwebbed to PC
    Posts
    311

    Resolved [RESOLVED] Time period NumericUpDown type control?

    Hi Folks

    I have an application in which I would like the user to be able to type or select a time period, so that they can indicate that a process should be run for that length of time.

    E.g. 00:05:20 for 5 minutes and 20 seconds or 32:00:00 for 32 hours.

    I have looked at the normal NumericUpDown, but it doesn't appear to accept anything other than decimal numbers.
    I have also looked at the DateTimePicker, which looks good at first, I can set ShowUpDown to True, Format to Custom and CustomFormat to HH:mm:ss.
    However it does not allow periods greater than 24 hours as it always roles over to 00:00:00 after that. I have a suspicion that this is because it is still talking to itself in dates in the background and the roll-over is actually the picker looking ahead to the next day's date.

    So my question is simply this: is there a "normal" pattern or control that is used to do this job, or will I be looking at rolling my own?

    Thanks
    Thanks

  2. #2
    eXtreme Programmer .paul.'s Avatar
    Join Date
    May 2007
    Location
    Chelmsford UK
    Posts
    26,424

    Re: Time period NumericUpDown type control?


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width