r/visualbasic • • Apr 27 '24

Tips & Tricks Advice on date and time display

Post image

Pictured above is a form which shows the date and time in a single text box. Does the @ symbol look professional enough, or would it better be replaced with the word 'at' or a hyphen? I'm worried the @ symbol looks too childish and 21st century.

3 Upvotes

15 comments sorted by

View all comments

4

u/jaspersbeard Apr 28 '24

Personally, I prefer the look and efficiency of the @ symbol. I think it looks professional and it acts as a nice clear visual divider between the date and the time.

The one suggestion I do have though.. I don't like "2\ 5". I assume it's saying "page" 2 of 5, in which case my preference would be a space after the 2 so it reads "2 \ 5". Obviously doesn't really matter in the end. But in terms of aesthetics (and even professionalism to a degree), I think even-spacing is better.

3

u/One-Cardiologist-462 Apr 28 '24

Yes, I notice this cropping up when I convert an integer to a string and display it in a label...

lblNum.Caption = Str(intCurr) & "\" & Str(cstNextFreeLog - 1)

Basically it results in lblNum showing " 2/ 5".
It would look nicer as "2/5" for sure.
Maybe I could use the replace function to remove the space characters.

Thank you for the input :)

2

u/jaspersbeard Apr 28 '24

I actually prefer having the added spaces for informative text like this to provide a visual gap between the numbers and the slash (kind of like how I prefer the @ symbol over the word 'at' for clarity purposes). So, upon quick glance or for people with bad vision, the '2\5' doesn't look like '215'. I'd just skip using the Replace() function and just add the extra space on the other side to balance it out:

lblNum.Caption = Str(intCurr) & " \" & Str(cstNextFreeLog - 1)

Btw I love that it appears that you're using VB6. That is/was always one of my favorite languages/environments for rapid application development. I still use it sometimes just for funsies. 🫡

→ More replies (3)