Welcome to our new forum
All users of the legacy CODESYS Forums, please create a new account at account.codesys.com. But make sure to use the same E-Mail address as in the old Forum. Then your posts will be matched. Close

SysFile Libary

SPS-Prog
2018-08-28
2018-09-03
  • SPS-Prog - 2018-08-28

    Hallo zusammen,

    beim schreiben von Datein habe ich folgendes Problem.

    Der Append Mode funktioniert nicht!

    Wenn ich Das File im Append Mode öffne und dann SysFileWrite ausführe. Meldet SysFileWrite zurück, dass es die vorgegebene Anzahl an Bytes geschrieben hat. Öffne ich das File allerdings, dann wurde der Inhalt nicht geschrieben.

    Hat jemand schon erfahrungen mit der SysFile Lib und dem Raspberry?

     
  • plcmax - 2018-09-03

    Hi,
    also bei mir geht das:
    ich mach es so (verwendet Sysfile library):

    dwFile := SysFileOpen(szFile:=sFileName, am := SysFile.AM_APPEND_PLUS, pResult := ADR(result));
    IF result <> 0 THEN
       bError := TRUE;      (*error: can't be opened *)
       RETURN;
    END_IF
    

    Viele Grüsse
    plcmax

     

Log in to post a comment.