Show the Line No. of the line above

Yes it is a manual entry, How could you make a lookup on this field ? the probleme, when you have several rows for exampl

Line No. Type Attached to Line No.

10000 Item

20000 Item

30000 20000

35000 (I want to attach this line to Line No. 20000)

40000 Item

you can’t do lookup ! my solution is to find the first Item above the line that I want to attach … bu I don’t know how ??! (and the problem here I dont know the Line No. of created line when I do my treatment)