[Common]
Description=
HotKeyStart=119
HotKeyStop=122
Enabled=1
RunOnce=1

[Script]
var handle=0
var s=""
Main:
  //创建文件，并写入一些内容
  set handle=SEFileCreate("test.txt")
  do SEFileWrite(handle,"a string line 1"+AsciiToChar(13)+AsciiToChar(10))
  do SEFileWriteLn(handle,"a string line 2")
  do SEFileAppend(handle,"a string line 3"+AsciiToChar(13)+AsciiToChar(10))
  do SEFileAppendLn(handle,"a string line 4")
  do SEFileClose(Handle)
  //重新打开上面的文件
  set handle=SEFileOpen("test.txt")
  do SEFileAppendLn(handle,"reopen ok")
  do SEFileSeek(handle,0,0)
  set s=SEFileRead(handle,15)
  do ShowMsg(s)
  set s=SEFileReadLn(Handle)
  do ShowMsg(s)
  do SEFileClose(Handle)
EndMain
