Hello @VIGNESH_BABU
You can use MCUXpresso config tool inside MCUXpress IDE to config Ctimer to Captrue mode.
As below:

After configuration as your requirement, Update code. Code will be generated automatically.
Hope it helps. Can contact us if still have any issue with it.
Best Regards,
Alice