You can only sub on a player who is currently playing in a game that is in the same flight as the player you intend to sub off. 

For Example:
You have Eden Hazard on your team and Chelsea is currently against Manchester United.
Hazard suffers an injury and you want to replace him with Kevin De Bruyne, who is playing in Manchester City's match against Everton. 

If the Manchester City vs. Everton match started at the same time, then De Bruyne is eligible to come on as a substitute.

You will receive the points from Hazard up to the point of substitution. After that you will receive the points De Bruyne accumulates while he is on the pitch.