To get 17 minutes you need to have 7 and 10 cross at the same time, otherwise you will have more than 17 minutes as you will have 10+1, 7+1, 1+2 or something along those lines, that adds to more than 17. If you let them go first however you will need 7 to come back (as that is the quickest one) and that would make your time go over 17 minutes. So what you need to do is get 1 and 2 to go first, so that 1 can bring the lantern back for 7 and 10, who will be going next. Once 7 and 10 have both arrived back at the other end of the bridge 2 can go back across to go and retrieve 1. Then 1 and 2 will come back, making your total time 17 minutes.
Bridge Crossings Summary:
1+2 go across first: It takes 2 minutes so the Total Time is 2 minutes
1 goes back across to take the lamp back: It takes 1 minute so the Total Time is 3 minutes
7+10 go across: It takes 10 minutes so the Total Time is 13 minutes
2 is at the other end so they go across with the lamp to retrieve 1: It takes 2 minutes so the Total Time is 15 minutes.
1+2 go back across: It takes 2 minutes so the Total Time is 17 minutes
There we go! We have managed to get all 4 people across in the 17 minutes!