How can I find index of spline point

You have to interate over the spline points using a for loop. GetNumberOfSplinePoints give you how many points and GetDistanceAlongSplineAtSplinePoint will tell you how far the point is along the spline.

You need to get through all the points and find the nearest one to your current distance…