#1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 109
Default date code

How to tell a Textbox(on a userform) and the user to enter date value in
"dd/mm/yy" format.

--
Message posted via http://www.officekb.com

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 389
Default date code

Dim v As Variant
Do
v = InputBox("Enter a date")
If StrPtr(v) = 0 Then Exit Sub
Loop While Not IsDate(v)
Me.TextBox1.Text = Format(v, "dd/mm/yy")


--
Tim Zych
www.higherdata.com
Compare data in worksheets and find differences with Workbook Compare
A free, powerful, flexible Excel utility

"tkraju via OfficeKB.com" <u16627@uwe wrote in message
news:85202c0024350@uwe...
How to tell a Textbox(on a userform) and the user to enter date value in
"dd/mm/yy" format.

--
Message posted via http://www.officekb.com



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 109
Default date code

Mr.Tim,
Can this code be used for a TextBox in A userform ?
Where are messages ? where to insert the code?

Tim Zych wrote:
Dim v As Variant
Do
v = InputBox("Enter a date")
If StrPtr(v) = 0 Then Exit Sub
Loop While Not IsDate(v)
Me.TextBox1.Text = Format(v, "dd/mm/yy")

How to tell a Textbox(on a userform) and the user to enter date value in
"dd/mm/yy" format.


--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200806/1

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 389
Default date code

Check out:

http://www.contextures.com/xlUserForm01.html

--
Tim Zych
www.higherdata.com
Compare data in worksheets and find differences with Workbook Compare
A free, powerful, flexible Excel utility

"tkraju via OfficeKB.com" <u16627@uwe wrote in message
news:8521c019e1429@uwe...
Mr.Tim,
Can this code be used for a TextBox in A userform ?
Where are messages ? where to insert the code?

Tim Zych wrote:
Dim v As Variant
Do
v = InputBox("Enter a date")
If StrPtr(v) = 0 Then Exit Sub
Loop While Not IsDate(v)
Me.TextBox1.Text = Format(v, "dd/mm/yy")

How to tell a Textbox(on a userform) and the user to enter date value in
"dd/mm/yy" format.


--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200806/1



  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 109
Default date code

this is not what I want.I want to enter date value in textbox directly in
dd/mm/yy format.Textbox has to accept the date value what I mean entering the
date value.
If I enter today's date as 05/06/08(means 5thJune2008) it should not be
converted into 6thMay2008.
No input box,entry directly in Textbox.
Tim Zych wrote:
Check out:

http://www.contextures.com/xlUserForm01.html

Mr.Tim,
Can this code be used for a TextBox in A userform ?

[quoted text clipped - 9 lines]
How to tell a Textbox(on a userform) and the user to enter date value in
"dd/mm/yy" format.


--
Message posted via http://www.officekb.com



  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 389
Default date code

Check out

http://www.cpearson.com/excel/newposte.htm

It will help you in constructing a post so that you have a better chance in
getting the response you are looking for.


--
Tim Zych
www.higherdata.com
Compare data in worksheets and find differences with Workbook Compare
A free, powerful, flexible Excel utility


"tkraju via OfficeKB.com" <u16627@uwe wrote in message
news:853aa5d4351ef@uwe...
this is not what I want.I want to enter date value in textbox directly in
dd/mm/yy format.Textbox has to accept the date value what I mean entering
the
date value.
If I enter today's date as 05/06/08(means 5thJune2008) it should not be
converted into 6thMay2008.
No input box,entry directly in Textbox.
Tim Zych wrote:
Check out:

http://www.contextures.com/xlUserForm01.html

Mr.Tim,
Can this code be used for a TextBox in A userform ?

[quoted text clipped - 9 lines]
How to tell a Textbox(on a userform) and the user to enter date value
in
"dd/mm/yy" format.


--
Message posted via http://www.officekb.com



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Code to conditional format all black after date specified in code? wx4usa Excel Discussion (Misc queries) 3 December 26th 08 07:06 PM
Strange? VBA code returns wrong date format (not a date) zzxxcc Excel Programming 8 October 12th 07 09:13 AM
Convert a julian gregorian date code into a regular date Robert Excel Worksheet Functions 3 June 13th 06 07:03 PM
code to convert date from TEXT format (03-02) to DATE format (200203) Gauthier[_2_] Excel Programming 0 September 22nd 04 03:26 PM
code pasting a date changes date format in current month only Edward[_5_] Excel Programming 0 May 10th 04 06:13 PM


All times are GMT +1. The time now is 06:32 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"