date format in user form

G

Guest

Hi,Everybody,my code is Textbox1.value=ws.range("A2")
work sheet range A2 is a date dd-mmm-yy format,I am getting Textbox1 value
as mm/dd/yyyy format .What is the line of code to textbox1.value in dd-mmm-yy
format.
 
N

Norman Jones

Hi Tungana,

Try:

TextBox1.Value = _
ws.Format(Range("A2").Value, "dd-mmm-yy")
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top