You are welcome and thanks for the rep.

Is is a very simple code so I hope you will understand easily.