That was exactly what I needed, code is done. I'll add tests and debug tomorrow, should have it done by end of day.