Sub ExtraireLigne(nligne As Int,text As String) As String
Dim aPos,bPos As Int=0
Dim t As String
Dim c As Byte = 26
text=text.Trim
For n=0 To nligne-1
Try
bPos=text.IndexOf2(Chr(10),aPos)
Catch
End Try'ignore
Try
If bPos = -1 Then
bPos=text.Length
End If
If bPos-aPos>26 Then
Do While text.CharAt(aPos+c)<>" "
c=c-1
Loop
bPos=aPos+c
End If
If aPos>text.Length Then
t=""
Return t
End If
t=text.SubString2(aPos,bPos)
Catch
t=""
End Try
aPos=bPos+1
Next
Return t
End Sub