Visual Basic & Date

  KW2K 21:22 26 Mar 2004

Hi everyone,
Does anyone out their know what the code is for displaying the current date and time in Visual Basic in the folowing format: 26 Oct Thursday 2004 14:23:00. Or does anyone know if their is a Visual Basic forum which could answer this question.


IN all cells that you require the format use
Format Cells - Custom and use the following format.

dd mmm dddd yyyy hh:mm:ss

If you specifically require it in VBA then the following code would set A1 accordingly


Selection.NumberFormat = "dd mmm dddd yyyy hh:mm:ss"

  KW2K 00:09 27 Mar 2004

Hi Whisperer,
Thanks for the code, worked a treat !


This thread is now locked and can not be replied to.

Elsewhere on IDG sites

OnePlus 5 review

50 best online Adobe XD tutorials

iPad Pro 10.5in (2017) review

Comment connecter un MacBook à une TV ?