Excel vba: Is it possible to initialise an array of dates in one-line with brackets? -


i'm new excel vba , having trouble initialising array of dates on single line using brackets.

i know how variant data types:
arrayvariant = array("hello", "world")
, string data types:
arraystring = split("hello,world",",")
, can initialise array of dates initialising each item individually:
arraydates(0) = #01/01/1900# etc
can't find way initalise date array on single line. possible in vba?

you can use same approach string type, converting each value date type, using cdate():

arraydates = array(cdate("1/1/2000"), cdate("2/2/2000"), cdate("2/3/2004")) 

by using approach manage fill array in 1 line.


Comments

Popular posts from this blog

resizing Telegram inline keyboard -

command line - How can a Python program background itself? -

php - "cURL error 28: Resolving timed out" on Wordpress on Azure App Service on Linux -