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
Obwohl die Bibliothek StringUtils mit der Funktion LEN eingebunden ist
lässt sich die Funktion LEN nicht übersetzen.
PROGRAM Fhandle
VAR
fwrite:BOOL:=FALSE;
fread:BOOL:=FALSE;
fdel:BOOL:=FALSE;
hndl:DWORD;
erg:RTS_IEC_RESULT;
text:STRING:='Eine Zeile';
END_VAR
IF fwrite THEN
hndl:=sysfileopen('/mnt/ramdisk/test.txt',ACCESS_MODE.AM_WRITE,erg);
sysfilewrite(hndl,ADR(text),LEN(text),erg);
sysfileclose(hndl);
fwrite:=FALSE;
END_IF;
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Obwohl die Bibliothek StringUtils mit der Funktion LEN eingebunden ist
lässt sich die Funktion LEN nicht übersetzen.
PROGRAM Fhandle
VAR
fwrite:BOOL:=FALSE;
fread:BOOL:=FALSE;
fdel:BOOL:=FALSE;
hndl:DWORD;
erg:RTS_IEC_RESULT;
text:STRING:='Eine Zeile';
END_VAR
IF fwrite THEN
hndl:=sysfileopen('/mnt/ramdisk/test.txt',ACCESS_MODE.AM_WRITE,erg);
sysfilewrite(hndl,ADR(text),LEN(text),erg);
sysfileclose(hndl);
fwrite:=FALSE;
END_IF;
hallo,
ich verwende immer SIZEOF(text) ...