In reply to m_v:
What do you mean by “not working”? Are you getting a compilation error? Run-time error? Are you not seeing the results you expect? How are you testing?
It would help to show a minimal compete example of what you are trying to accomplish.