Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Coding for Calendar control in VB 6

Posted on 2004-08-30
3
175 Views
Last Modified: 2010-05-02
I have a form name frmReport it has a text field named txtDate. It also has a button that, when clicked, opens a form called frmDate. frmDate has the MS calendar control 8.0 component on it. What I would like to do is when a user opens frmDate and clicks on a particular date, frmDate will close and the selected date will appear in txtDate on frmReport. How can I do this. Thanks.
0
Comment
Question by:Mike Miller
  • 2
3 Comments
 
LVL 22

Accepted Solution

by:
DarkoLord earned 500 total points
ID: 11934484
Hi... Put this on frmDate:

Private Sub Calendar1_Click()
     frmReport.txtDate = CStr(Calendar1.Value)
     Unload Me
End Sub

Darko
0
 

Author Comment

by:Mike Miller
ID: 11934524
You're awesome...Thanks!!!
0
 
LVL 22

Expert Comment

by:DarkoLord
ID: 11934547
You're welcome
0

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
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…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

840 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