dim H, M, S, AMPM as strings

DTPicker1.Hour = H
DTPicker1.Minute = M
DTPicker1.Second = S
DTPicker1.?????? = AMPM

im having a problem on how i can change the DTpickers AM/PM in codes

im trying to load a time from a database to DTPicker,

ive Split the (field loaded on the database) to H M S
and also AMPM

pls help me on this guys... thanks in advance

I believe this should get you started...

DTPicker1.Format = dtpCustom
DTPicker1.CustomFormat = "MM/dd/yyyy hh:mm:ss tt"

Good Luck

thx for the reply sir,

but im loading the data i stored in a database to the DTpicker,

how can i set my (strings) to HH:MM:SS TT?

still cant get it,

heres my code sir

Private Sub SchedMidnightTime()
TOT = RSSchedule.Fields("MidnightTIME")

Me.Show
i = Split(TOT, ":")
H = i(0)
M = i(1)
S = i(2)

d = Split(S, " ")
S = d(0)
ampm = d(1)

'Debug.Print S
'dtMDR is my DTpicker

dtMDR.Hour = H
dtMDR.Minute = M
dtMDR.Second = S
'after ive loaded the Hours,Minutes,Seconds and am/pm  from a 'database i dont know how to load  [QUOTE]ampm[/QUOTE]?

Edited 3 Years Ago by pritaeas: fixed formatting

This question has already been answered. Start a new discussion instead.