I'm trying to populate a textbox with the current time.
The format I want is ie. 5:30 PM.
The following code:
TextBox1.Text = Strings.Format(Now, "hh:mm AM/PM")
you may want to look into the date.toShortTime and .toLongTime methods. Or if you are just formating a date, you can use now.tostring("hh:mm ") I can't remember what character represents the am/pm indicator, but pull up the documentation on data.tostring, I know it's in there.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.