How to get playtime duration of a file?

Hi @dmakheja

kindly check this out
they have a sample code

Thanks