Why post it like this?
Post the code directly with code tags.
Sub txtSearch_EnterPressed()
' Dim vuoto As String
Dim pippo As String
Dim RigaDaCercare As String
TIMER1.Enabled=True
Dim IndexOf As Int
Label3.Visible =False
pippo=txtSearch.Text
txtSearch.Text=""
lstrighe.Initialize
lstrighe = File.ReadList(File.DirDefaultExternal, "/anaiper/hj.txt")
RigaDaCercare = "pluto"
IndexOf = lstrighe.IndexOf(RigaDaCercare)
lstrighe.InsertAt(IndexOf + 1,pippo & Chr(10) & Chr(13) )
File.WriteList(File.DirDefaultExternal, "/anaiper/hj.txt",lstrighe)
txtSearch.RequestFocus
End sub
Several mistakes:
1. File.DirDefaultExternal should
never be used. Use RuntimePermissions.GetSafeDirDefaultExternal("") instead.
2. Remove this: & Chr(10) & Chr(13)
File.WriteList adds the end of line character (Chr(10)) automatically.
Note that windows end of line = Chr (13) & Chr(10)