@molly:
Thank you very much for your TFileStream-Example...
..you have your desktop cluttered with about 10+ open application windows then the problem becomes clearly visible.
Ok, that's possible, I normally don't use so much programs at the same time, so maybe that's the reason why I didn't see anything like that...
My individual maximum is normally 4 or 5 PRG's at the same time.
...What is the reason to _load_ the already stored loglines ?
For me it's quite interesting to see if there was maybe another problem ealier...
In some cases it's even of interest how many ErrorMessages of the same type are in the log. Sometimes it's easier to calculate what the problem is.
Reason why i usually truncate logfiles around 100/200 MB.
Ok, that's big... In my case those files are very small and mostly only important during the program creation...
Of Course, when the program is ready I don't want to see anything like that..
Now I've got 3 Versions:
See the attachment...
The Restore Version normally needs a Path-Correction, but I couldn't manage this without a Delay or Sleep or Timer...
So I decided to stop trying for now...
All steps that are necessary are separately watched were easy... but when it comes to put them all together, then a special timing is needed otherwise it wouldn't work.
I mean this:
1. Bring the window to top
2. Send VK_F4 and VK_ESCAPE to the WinEx-Window
3. Find the EDIT-comp of the WinEx-Window
4. Send the Path with WM_SetText
5. Finally send VK_Return
All steps are very easy, but all together in one step and very fast they are not that easy for me... and when I use Sleep then it takes too much time... compared to the other versions.
But no problem at all... I've got my versions and they are running fine so far... (the first version is sometimes not able to bring the second window to front, but the other 2 Versions are running stable on my machine)