Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
hi,
i am using VBScript in QlikView, i have one array, which contains the list of dates, but i want to get the maximum date from the array.
so how can i get it using VBScript?
Hi,
Try like this
MaxDate = CDate(MyArray(0))
for i = 1 to MyArray.Count -1
if CDate(MyArray(i)) > MaxDate then
MaxDate = CDate(MyArray(i))
next
Celambarasan
Something like this?
dtmMaxDate = 0
for i = 0 to MyArray.Count -1
if MyArray(i)> dtmMaxDate then dtmMaxDate = MyArray(i)
next
msgbox dtmMaxDate
Hi,
How you store the dates in array?
Celambarasan
Hi,
Try like this
MaxDate = CDate(MyArray(0))
for i = 1 to MyArray.Count -1
if CDate(MyArray(i)) > MaxDate then
MaxDate = CDate(MyArray(i))
next
Celambarasan
Thanks for reply Celambarasan