Archive for August, 2004

Date & Time Basics

Tuesday, August 31st, 2004

Creating a column of consecutive dates is easy with the OOo Calc tool.

dragdown_dates.jpg

The formulas below illustrate how to increment a particular date by a given number of days, months, or years…

adding_dates.jpg

Extracting a filename from a full path (Windows)

Saturday, August 28th, 2004

This would be an easy task if we were looking for the first backslash in the full pathname.

We need to first determine the number of backslashes by figuring out the lenght of the original path with the backslashes removed …

LEN(A1)-LEN(SUBSTITUTE(A1;”\”;”")

We now swap out the last backslah with a space character - CHAR(13) ..

SUBSTITUTE(A1;”\”;CHAR(13);LEN(A1)-LEN(SUBSTITUTE(A1;”\”;”")

Finally, we use the MID function complete the extraction of the filename.

=MID(A1;FIND(CHAR(13);SUBSTITUTE(A1;”\”;CHAR(13);LEN(A1)-LEN(SUBSTITUTE(A1;”\”;”")

filename_extract.jpg