Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Outlook-style time entry
Message
De
09/11/2001 03:00:27
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Divers
Thread ID:
00579395
Message ID:
00579531
Vues:
28
>We'd like to use comboboxes similar to Outlook in a VFP 6.0 app, for the entry of time values. When I say 'similar to Outlook', I mean the following behaviors:
>
  • Preset list of times (every half hour or so)

  • >
  • User can type in the desired time if it's not displayed. Formatting is updated when they leave the field

  • >
  • When the start time is changed, the end time changes accordingly

  • >
  • When the start time is changed, the rowsource for the end time combobox is modified to exclude times earlier than listed in the start time combobox

  • >
  • If the user wants to change the length of the appointment, they do so by simply changing the end time (via typing or selection), which does not affect the start time.

  • >
  • We would like to store the time as a string in the format 'HH:MM AM'

  • >
  • Ideally, we want an all-VFP solution

  • >
    >Has anyone done this before? Any pointers or gotchas on doing it?
    >Thanks!
    >zahid

    Zahid,
    We've done it.

    -Start at 0, increment 30*60 secs, end at 24.
    -Add seconds to dtot(date()) and get ttoc(,2) for time portion -ttoc(dtot(date()),2)-
    -This fills combos initially (30 mins inc).
    -Overlay combo and FoxyClasses TimePick control to accept nonexistant valid time
    (Instead of timepick you could develop your solution say via keypress checking)
    -In lostfocus of first reset and refill second if needed
    Cetin
    Çetin Basöz

    The way to Go
    Flutter - For mobile, web and desktop.
    World's most advanced open source relational database.
    .Net for foxheads - Blog (main)
    FoxSharp - Blog (mirror)
    Welcome to FoxyClasses

    LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
    Précédent
    Répondre
    Fil
    Voir

    Click here to load this message in the networking platform