|
From: Anne on 27 Oct 2006 06:11 Hello: I need to control if any change has done in a text file. So, it can be to read the file in a infinite loop and when a change is done, write this change in a text field? Can you tell me how to do this? thanks a lot.
From: Manno Bult on 27 Oct 2006 08:20 Hi Anne, I'd go with reading the modification date of the file with an Xtra (budApi or FileXtra4) and if modification date is different from the last time you read the file, read it again. This way you don't need to open the file to check it's content. However, I think the most accurate those Xtras are is seconds. If so, twoo changes to the same file in one second would not register. in pseudo code: in initialization: read file, fill field member read and store modification data in loop: on exitFrame me (or some timeout eventhandler) read modification date if different from previously stored read file, fill field member read and store modification date end if end Hope this helps Manno Anne wrote: > Hello: > I need to control if any change has done in a text file. So, it can be to > read the file in a infinite loop and when a change is done, write this > change in a text field? > Can you tell me how to do this? > thanks a lot. > > -- ---------- Manno Bult manno(a)xs4all.nl
|
Pages: 1 Prev: Xtra no loger recognised help Next: how to use in Lingo XML-RPC file |