Solved

DTPicker Format

Posted on 2002-06-03
5
1,318 Views
Last Modified: 2007-11-27
I use DTPicker in my form. The format is like 06/11/99, time is not shown.

I want to change the format as
11-Jun-99 9:45 am.
I tried to define the custom format in the property page, but i failed.

Can someone tell me how to achieve this
0
Comment
Question by:huhu
  • 3
  • 2
5 Comments
 
LVL 38

Expert Comment

by:PaulHews
ID: 7051771
Change the format property to 3 - dtpCustom

Then change the CustomFormat property to dd-mm-yyyy hh:mm tt
0
 
LVL 38

Accepted Solution

by:
PaulHews earned 100 total points
ID: 7051776
Sorry dd-MMM-yyyy hh:mm:ss tt
0
 
LVL 18

Expert Comment

by:bobbit31
ID: 7051793
dtpicker control doesn't store time... but this should work:

DTPicker1.Format = dtpCustom
DTPicker1.CustomFormat = "dd-mm-yy"
0
 
LVL 18

Expert Comment

by:bobbit31
ID: 7051801
oops, PaulHews is right ;) i was using the wrong format string (been working w/ java too much)
0
 
LVL 38

Expert Comment

by:PaulHews
ID: 7051815
>PaulHews is right

Well I'm close anyway.  ;)

>11-Jun-99 9:45 am

format: dd-MMM-yy hh:mm tt
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now