ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Copy Column Width (https://www.excelbanter.com/excel-programming/444541-re-copy-column-width.html)

Steve[_4_]

Copy Column Width
 
Hey Garry,

One last quick one if I may...can I replace a "blank" entry in my textbox (upon clicking the ok button) with a timestamp (or something unique)?

GS[_2_]

Copy Column Width
 
It happens that Steve formulated :
Hey Garry,

One last quick one if I may...can I replace a "blank" entry in my textbox
(upon clicking the ok button) with a timestamp (or something unique)?


Something like...?

Private Sub cmdOK_Click()
Dim sTemp
If Me.TextBox1.Text = "" Then
' sTemp = Now() '//date and time
sTemp = TimeValue(Now()) '//time only
Else
sTemp = Me.TextBox1.Text
End If
End Sub

--
Garry

Free usenet access at http://www.eternal-september.org
ClassicVB Users Regroup! comp.lang.basic.visual.misc




All times are GMT +1. The time now is 08:05 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com