How to read file content

Support for our english speaking visitors

Moderator: Co-Administratoren

Antworten
xachopin
Beiträge: 4
Registriert: 12.11.2014, 13:16

How to read file content

Beitrag von xachopin » 18.11.2014, 12:55

Hi,
I would like to download a file from a FTP server, and then open it to read the content.

If found the following command to acces the FTP and download the file locally (with CUxD)
dom.GetObject("CUxD.CUX2801001:1.CMD_EXEC").State("wget -O /tmp/temp.txt 'ftp://myserver/thefile.txt");

But then, I don't know how to read the file (at once on line by line, it does not matter) in a variable. Can anyone help?

leknilk0815
Beiträge: 6693
Registriert: 19.03.2007, 08:21
Danksagung erhalten: 2 Mal

Re: How to read file content

Beitrag von leknilk0815 » 18.11.2014, 17:06

Hi,
i can't help you, but here is a TCL- script to get some infos from the german weather service DWD.
Maybe you can find an "inspiration"...
http://homematic-forum.de/forum/downloa ... hp?id=9557
Gruß - Toni

KS300 + Sonnendauer + Windrichtung, KS888, HM-CC-TC/HM-CC-VD, FHT80b, und etwas FS20-xx, Keymatic, EM1000, CCU2 und FHZ2000 sowie HP Studio, HPCL + Upgrade für FHZ

Antworten

Zurück zu „HomeMatic - english“