说三道四技术文摘-感悟人生的经典句子
说三道四 > 文档快照

查找月份的最后一天-VB资料

HTML文档下载 WORD文档下载 PDF文档下载
查找月份的最后一天-VB资料
In many industries (particularly in the insurance industry), it注释:s important to know the last day of the month. To find the last day of a given month, add a text box and a command button to a form. Enter the following code in the command button:

Dim TEMP2 As Date
Dim nLastDay As Integer
TEMP2 = InputBox$("Please Enter A Date", "LastDay")
nLastDay = DatePart("d", DateAdd("M", 1, TEMP2 - DatePart("d", TEMP2)))
Text1.Text = nLastDay
When you run the application and click the button, you注释:ll be prompted for a date. Then, the program will display the last day of that month of any year.
备案号:鲁ICP备13029499号-2 说三道四 www.s3d4.cn 说三道四技术文摘