How to handle sequence browser frame slider

Hi I am trying to handle sequence browser frame slider , I found a way to get the index, but I want to connect a function when the slider value changes how can I achieve it

sequenceBrowserNode = slicer.mrmlScene.GetFirstNodeByClass(“vtkMRMLSequenceBrowserNode”)
if sequenceBrowserNode:
sequenceBrowserNode.AddObserver(sequenceBrowserNode.ModifiedEvent, self.onFrameChanged)

this was the method I used Kindly help me out as

A post was merged into an existing topic: How to handle slider in the slicer widget