Dear All,
Libreoffice 6.0 on Ubuntu 18.
I have a macro with custom function:
public function tt( myrange as variant )
a = myrange(0,0)
msgbox(a)
end function
I refer to my function from a cell like “=TT(A1)”
If cell “A1” being passed to the function contains a date value “2012-01-01”, then variable “a” in the function will not contain a string of “2012-01-01” but instead I get an integer “40909” representing the date in numeric form. However I need the former one because it cannot be decided from the integers if they are representing date values.
How could I get the displayed text of all cells in the range that are passed to my function instead their underlying numeric values? Is it a problem that I get an array as an argument that has not methods to get the .value or .formula, and not a range type? How could I achive that?
Thank you.