Error opening files, when associated program takes too long

Please report only one bug per message!

Moderators: white, Hacker, petermad, Stefan2

Post Reply
Max Born
Junior Member
Junior Member
Posts: 13
Joined: 2007-11-16, 18:48 UTC

Error opening files, when associated program takes too long

Post by *Max Born »

Hi, let me first said that total commander is the most useful tool there is for windows. It let people ditch explorer, winzip…and a bunch of other small cranky program. Great relive. It owed much to the genius of peter Nortor for inventing NC, but you guys have take it to a whole new level. Ok, enough praise, down to business.

I have being experiencing, consistently, two annoying problems with total commander. The kind of problem that makes you feel insecure about a program. And I meant insecure in the sense that the program stops behaving predictably, because sometimes it works, sometimes it doesn’t. It is as frustrating as having a mouse with an inconsistent clic.
One of the problems is that if a program takes too long to open a file, TC give up waiting ant thrown an error. Afterwards the program opens, but no file is open. An example:

1. In TC double clic or enter (open) over a file of type .opj (Originlab Origin Project). Or any file that need to be opened by a program that takes a while to load. It could be because the program is heavy or the PC slow.

2. TC seemed to be waiting for the file to open, even the cursor changes to busy. Sometime later, TC towns an error (error opening program (29) or something like that), and gives up.

3. After a little more the program that was supposed to open the original file, ends loading and is shown, but it do not open the file. For instance OrignLab Origin opens, but the project file (.opj) is not loaded.

4. If afterwards you try to open the file in TC again, it opens in a second. No error this time.

Conclusion, the real problem is that TC stops waiting for the program to load. Maybe is even a windows problem. The problem is hard to reproduce because the second time you tried to open a similar file, the program loads much faster, and there is no error.

It have happen to me even with .docx documents.

Could it be possible to instruct TC to wait longer, or is this a windows api problem?

I´m not sure, but I think this problems occur on Windows XP, 7, and 7 x64 (I use TC on them all).

I´m going to describe the other problem in another post, following the one error per post rule.

Thanks in advanced for any help in this matter.
Best regards,
MB.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48021
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Error 29 is SE_ERR_DDEFAIL, ' The DDE transaction failed. '.

The most common reason for this: You started TC with full admin rights, and the program which should open the file is already running, but with normal user rights.

DDE (dynamic data exchange) works with Windows messages, but Windows prevents messages between programs with normal and full rights.

Solution: Use Total Commander with normal user rights.
Author of Total Commander
https://www.ghisler.com
Max Born
Junior Member
Junior Member
Posts: 13
Joined: 2007-11-16, 18:48 UTC

Post by *Max Born »

Hi, Ghisler, thanks for the quick reply. The problem, indeed, seems to be related to inter-process communications in windows (To DDE in particular). I´m using TC with normal privileges, and it does not make a diference is TC is run as admin, or not. The error happens the first time a program that take a long time to load is called to open a file from TC. The second time I tried to open the file (inmediatelly after) it all works normally. Then, I thinks for suere this is a time-out error. What makes the time expire with such a high frequency in my computer, could be that it is somehow old and slow (not so much, soo).

Looking on the internet, i~ve found some indications that the DDE timeout could be set from the program that initiate te interprocess-comunication (for instance, take a looka at http://www.empix.com/NE%20HELP/tutorials/dde_fix.htm

Could something like a DDE Time Out value be incorporated in the configuration of TC, maybe as an ini file parameter? So people with slow computers could depend on TC to open files always, no matter how long it takes?

Thanks in advance, and best regards,

MB.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48021
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

I'm using ShellExecuteEx to launch programs. Unfortunately I cannot find any documentation on how to increase the DDE timeout used by ShellExecuteEx, sorry.
Author of Total Commander
https://www.ghisler.com
Max Born
Junior Member
Junior Member
Posts: 13
Joined: 2007-11-16, 18:48 UTC

Post by *Max Born »

Hi, Ghisler,
after making a few more test I have found that the problem described here also happens using Windows Explorer. So you can cross this one out. I now shift my attention to Windows, because wherever is happening is not TC fault. Sorry to have bother you with this. It took me so long to find it also happens in Explorer, because thanks to TC I never need to use explorer (lucky me).

Thank again,

Best regards,
M.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48021
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Did you check my comment about the launcher (TC, Explorer) and the target program running at different security levels? Windows does not allow to send messages from a program with a lower level to a program with a higher level. Since DDE sends messages in both directions, both programs need to run at the same level (e.g. both as normal user or both as administrator).
Author of Total Commander
https://www.ghisler.com
Post Reply