Razzak,
When Date/Time Picker is set for Date, a calender pops up when you click
on the drop down. When D/T Picker is set for Time, you "edit" hh or mm
by adjusting with the up/down arrows. Works fine. Is there some way to
have the adjustable Pop-up Clock come up when D/T Picker is set for Time
? I can make a version work in forms by placing a Speed Button next to
the D/T Picker, but I still have to go through the Dialog box.window to
get to the Pop-up Clock. We use multiple time inputs for many billing
purposes while the date often default to today. The inputs are scattered
though many forms, particularly for behind the scene editing using
scrolls several days later. The Pop-up Clock seems like a perfect KISS
solution in many situations, but I would like to avoid the Dialog box
window entirely for this particular purpose.
Tom Frederick
Jacksonville, IL
A. Razzak Memon wrote:
At 11:25 PM 8/2/2008, Tom Frederick wrote:
Is there some way to use the Pop-up Clock for Time with the Data/Time
Picker much like the Calender pops up for the Date portion?
Tom,
Use POPUP_DIALOG_TYPE DATETIME option for date and time to return the
variable as DATETIME.
Once the Calendar (for Date) and the Clock (for Time) options are
displayed, click on the appropriate day to select the date. Use left
click to set Hour and right click to set minute. Ctrl key restricts
to 5 minutes.
Here's how:
Example:
-- Start here ...
IF (CVAL('DATABASE')) <> 'RRBYW14' OR (CVAL('DATABASE')) IS NULL THEN
CONNECT RRBYW14 IDENTIFIED BY NONE
ENDIF
CLS
CLEAR VAR vDateTimeTxt, vDateTime
SET VAR vDateTimeTxt TEXT = NULL
SET VAR vDateTime DATETIME = NULL
DIALOG 'Enter Date and Time (mm/dd/yyyy hh:mm:ss ap)' +
vDateTimeTxt=32 vEndKey 1 +
CAPTION 'DIALOG with DateTime Pop-up' ICON APP OPTION +
POPUP_ENABLED TRUE +
|POPUP_DIALOG_TYPE DATETIME +
|POPUP_CLOCK_BACK_COLOR WHITE +
|POPUP_CLOCK_FACE_COLOR MINT BLACK +
|POPUP_CLOCK_HANDS_COLOR RED +
|POPUP_CLOCK_NUMBERS_COLOR GREEN +
|POPUP_CLOCK_HOURTICKS_COLOR GREEN +
|POPUP_CLOCK_MINUTETICKS_COLOR RED +
|POPUP_CALENDAR_BACK_COLOR WHITE +
|POPUP_CALENDAR_DAYS_COLOR BLACK +
|POPUP_CALENDAR_FILLDAYS_COLOR MINT BLUE +
|POPUP_CALENDAR_DAYSOFWEEK_COLOR RED +
|POPUP_CALENDAR_LINES_COLOR BLACK +
|POPUP_CALENDAR_SELBACK_COLOR WHITE +
|POPUP_CALENDAR_SELFORE_COLOR RED +
|POPUP_CALENDAR_TODAYFRAME_COLOR MAROON +
|THEMENAME Sports Blue
IF vDateTimeTxt IS NULL OR vDateTimeTxt = '[Esc]' THEN
GOTO Done
ELSE
SET VAR vDateTime = .vDateTimeTxt
-- Do what else you have to do here ..
ENDIF
LABEL Done
CLEAR VAR vDateTimeTxt,vDateTime,vEndKey
RETURN
-- End here ...
Hope that's what you are looking for!
Very Best R:egards,
Razzak.