Diese Seite mit anderen teilen ...

Informationen zum Thema:
WinDev Forum
Beiträge im Thema:
Erster Beitrag:
vor 2 Monaten, 3 Wochen
Letzter Beitrag:
vor 2 Monaten, 3 Wochen
Beteiligte Autoren:
GuenterP, Al, Steven Sitas

Analysis problems

Startbeitrag von GuenterP am 23.07.2017 17:03


this is just an info what can happen to an analysis. I know how to fix that - making a new analysis and copy the files from the old one and re-arrange files and links. It will just waste some time, at least two days.

There is an analysis with 64 files and 76 links. Not a big thing. This analysis has been tweaked and changed hundreds of times. And now I deleted a single file ("ANFAHRT") and all references to it in the associated program.

Among many other things, in the project's initialization code there is a simple loop to detect and HCreation(..) missing files in the target database:

MyString = HListFile("MyProject.wdd","",hLstNormal)+CR
MyLocalI = StringCount(MyString,CR)
FOR MyLocalA = 1 TO MyLocalI
MyFileName = ExtractString(MyString, MyLocalA, CR)
IF NOT HFileExist(MyFileName) THEN

And now HCreation(MyFileName) throws an error and says, that the deleted file is not in the analysis!

Means: HListFile(..) is able to see and include the deleted file name in MyString, but HCreation(..) is not able to create the file, because it has no info about the file.

Quick solution: I just created a file with the same name and a single item "dummy" in it. When restructuring the file, WD22 complains about a duplicate file name, but it works. I tried to remove / recreate this file for several times but the error stays. So I left it alone and it works for the time being.

Btw. I became a bit skeptical about the file system and could locate two links in the Link-List of the HF-CC which pointed to non-existing (= deleted) files!


Hello Guenter

I am wondering if the autocreate files option in the project setup would have created the missing file and also why you do the HCreation manually rather than use the project setup option. Have you had a problem with it in the past ?


von Al - am 23.07.2017 17:12
Hi AL,

some years ago, we had a lot of mails between Tech Support and myself going forth and back. A number of experiments showed that HCreationIfNotFound(..) is rather (very) slow and does not return enough info about errors. HCreation(..) is the only function which gives you full info about any errors and is a lot faster than HCreationIfNoTFound(..).

von GuenterP - am 23.07.2017 17:28
Hello Geunter

Yes, I agree with you about HCreationIfNotFound() being slow.
I was referring to the option in the"Files" section of the project description that offers to automatically create the data files if they are not found when they are first opened.
I always thought that was PCSoft's answer to the slow HCreationIfNotFound()


von Al - am 23.07.2017 17:44
Hi Guenter,

the same thing happened to me in v19 (or v17).
According to support the Analysis was "corrupted" and since "Repair the analysis" didn't fix it, I used the technique you described to create a new analysis.

Since I didn't see the problem in v20 or v21 I thought that PCSoft had fixed it, but here we go again ...

Steven Sitas

von Steven Sitas - am 24.07.2017 08:21
Hi Steven,

firstly some good news! I wanted to send the "damaged" analysis to PCS Tech Support. Created a new Project without database, copied the \MyProject.ana directory to the new project's directory, connected the analysis to the project, deleted the ANFAHRT file from the analysis, generated the analyis and ho and belo! the file was really gone and not requested from my small HCreation(..) FOR-TO-loop in the Project Code!

Conclusion: there must be some other .wdd file which influences the bahaviour of the program.

1 - I deleted the .cpl directory which more often than not causes interference with the program. No change!

2 - Changed the reference to the directory of the .wdd file

IF InTestMode(tmProject) THEN
MyString = HListFile("C:\My Projects\BackComfort\BackComfort.ana\BackComfort.wdd","",hLstNormal)+CR
MyString = HListFile("BackComfort.wdd","",hLstNormal)+CR //

von GuenterP - am 26.07.2017 06:34
Zur Information:
MySnip.de hat keinen Einfluss auf die Inhalte der Beiträge. Bitte kontaktieren Sie den Administrator des Forums bei Problemen oder Löschforderungen über die Kontaktseite.
Falls die Kontaktaufnahme mit dem Administrator des Forums fehlschlägt, kontaktieren Sie uns bitte über die in unserem Impressum angegebenen Daten.