Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi all,
txtCorActDue1 is one of TextBox on a form and FillDateIn is a procedure used to fill date in the textbox when enter event happens, but when FillDateIn is call like the following, there is alway a type mismatch error. I guess txtCorActDue1 default value is text but how can I designate an object instead of its default value passed? Clara Private Sub txtCorActDue1_Enter() FillDateIn txtCorActDue1 End Sub Private Sub FillDateIn(txBox As TextBox) txBox.text = Year(FormatDateTime(14 + Now(), vbShortDate)) & "/" & _ Month(FormatDateTime(14 + Now(), vbShortDate)) & "/" & _ Day(FormatDateTime(14 + Now(), vbShortDate)) End Sub |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Passing collections to an object | Excel Programming | |||
Passing a variant object to a C++ dll | Excel Programming | |||
passing an object | Excel Programming | |||
Formatting Textbox, passing values to worksheet | Excel Programming | |||
Calling a Sub passing Textbox name | Excel Programming |