From: Alpineskier on 11 Mar 2010 12:26 I have a date format stored in a string and want to format a date in a text box on a userform the same as my DateFormatString.
From: Bob Phillips on 11 Mar 2010 12:52 TextBox1.Text = Format(TextBox1.Text, DateFormatString) -- HTH Bob "Alpineskier" <Alpineskier(a)discussions.microsoft.com> wrote in message news:15FD5BE0-FE2C-4B3E-97E2-D5A96A6F8616(a)microsoft.com... >I have a date format stored in a string and want to format a date in a text > box on a userform the same as my DateFormatString.
From: Mike H on 11 Mar 2010 13:01 Hi, Try this Dim MyString As String MyString = "yyyy/mm/dd" TextBox1.Text = Format(Date, MyString) or for another date Mydate = #3/11/2000# Dim MyString As String MyString = "dd mmmm yyyy" TextBox1.Text = Format(Mydate, MyString) -- Mike When competing hypotheses are otherwise equal, adopt the hypothesis that introduces the fewest assumptions while still sufficiently answering the question. "Alpineskier" wrote: > I have a date format stored in a string and want to format a date in a text > box on a userform the same as my DateFormatString.
|
Pages: 1 Prev: Compare worksheets Next: Connecting to Access database to populate a combobox. |