如何检测 vb.net 中下个月的天数?

how to detect number of days of the succeeding month in vb.net?

我有两个日期时间选择器和一个文本框。一个是有效日期,另一个是到期日期。文本框用于两个日期时间选择器的结果天数。如果文本框超过下个月 5 天,则消息框将弹出消息 "The document was submitted beyond 5 days of the succeeding month!"

您可以使用:

Dim maxDate = New Date(Now.Year, Now.Month + 1, 5)