Microsoft KB Archive/151755

= Spindate.exe - DateTime Spinner Class Example =

Article ID: 151755

Article Last Modified on 3/15/2005

-

APPLIES TO


 * Microsoft Visual FoxPro 3.0 Standard Edition
 * Microsoft Visual FoxPro 3.0b Standard Edition
 * Microsoft Visual FoxPro 5.0 Standard Edition
 * Microsoft Visual FoxPro 6.0 Professional Edition

-



This article was previously published under Q151755



SUMMARY
Spindate.exe is a sample that demonstrates how to combine the functionality and appearance of the Spinner with a text box holding DateTime data.



MORE INFORMATION
The following files are available for download from the Microsoft Download Center:

Spindate.exe

For additional information about how to download Microsoft Support files, click the following article number to view the article in the Microsoft Knowledge Base:

119591 How to Obtain Microsoft Support Files from Online Services

Microsoft scanned this file for viruses. Microsoft used the most current virus-detection software that was available on the date that the file was posted. The file is stored on security-enhanced servers that help to prevent any unauthorized changes to the file. By design, spinners alone can be used only with numeric data. However, using a Custom container class, you can combine the functionality and appearance of the Spinner with a text box holding DateTime data.

This sample also allows you easier access to the data you are working with by providing custom ControlSource and Value properties, which work with the cntSpinDate class just as they do with other objects.

The changes to the Date and Time are based on where you place the cursor in the TextBox control. You may also use the Up and Down arrow keys to activate the Spinner events. A second text box displaying the corresponding Day of the Week is updated as changes are made. You can use the "Reset" button to set the text box value to the current Date and Time.

NOTE: The ControlSource property for the custom controls must be manually entered in the Property sheet.

To use this class with Visual FoxPro version 3.0 or 3.0b, you need to compile the class library first with this command: COMPILE FORM Spindate.vcx Spindate.exe contains the following files:   Readme.txt   -- contains a description of the class Spindate.vcx -- contains the cntSpinDate class Spindate.vct

Keywords: kbinfo kbdownload kboop kbfile kbsample KB151755

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.