displaying and selecting calendar date from dropdown textbox

there is anywhere, while developing on vb6, i can program two textboxes, one: is STARTING DATE, another one: ENDING DATE,  such that, instead of keying date in box, i can click inside the textbox or combox, browse and select a particular date i want. any comment or suggestion would be appreciated
winklezAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

GrahamSkanRetiredCommented:
Have you tried the DatePicker (DtPicker) control?
You could use two of them instead of textboxes.
0
GrahamSkanRetiredCommented:
Note. If the date picker is not in your toolbox, add the 'Microsoft Windows Common Controls-2 6.0' set via Project/Components.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
23637269Commented:
DtPicker is what I normally used.
If you have a restriction that prevents you from using that you could create a picturebox and add an array of smaller pictureboxes inside to represent a Day Squares.  You can insert text within each square for the day's info.  The mouse click within the square would let you know what the user picked.

The DtPicker that Graham Skan suggested would be much easier.
You know what they say, why reinvent the wheel :)

Thanks
Roger
0
The Ultimate Tool Kit for Technolgy Solution Provi

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy for valuable how-to assets including sample agreements, checklists, flowcharts, and more!

dentabCommented:
I would use the date picker although I have created my own in the past.

If you dont want to have the common controls dependancy, try this:
http://ccrp.mvps.org/controls/ccrpdtp6.htm
0
winklezAuthor Commented:
then how do u set the dtpicker to today date ? otherwise, how can u make the dtpicker to open up the current month calender and i choose myself the right date? ; the here the dtpicker is loading the 30 jan 2006 as the default date  however it could be more easier for me, if loaded with today date.
thanks for endless support
0
GrahamSkanRetiredCommented:
Set the value in the Form load event
Private Sub Form_Load()
    DTPicker1.Value = Now
End Sub

Open in new window

0
dentabCommented:
you need on form load to set the date property to equal now...

e.g.

  DTPicker1.Value = Now
0
dentabCommented:
doh, 1 min beffore me :)
0
dentabCommented:
Then all I can suggest is that if the end-date is usually a set time away, then you could also set that

e.g.

Private Sub Form_Load()
  DTPicker1.Value = Now
  DTPicker2.Value = DateAdd("D", 7, Now)
End Sub

0
winklezAuthor Commented:
thanks 4 ur excellent work! keep it up
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Visual Basic Classic

From novice to tech pro — start learning today.