added GetLOC function