TGD File Association in Windows 7-64: Bug or Oversight?

Started by PabloMack, April 02, 2010, 11:09:01 PM

Previous topic - Next topic

PabloMack

[Sorry, this should have gone into the Support section]

As a software developer, it was only last year that I learned out how to associate a file type with a program that I wrote and have the program open the data file and know what to do with it when I double-clicked on its icon.  So I associated the TGD file extension with the Terragen 2 exectuable.  But when I double click on my first project that I saved, Windows 7-64 gives me the following error.  

[attachimg=#]

However, I can load the file from TG2 and its seems to work just fine.  File association with the editor I wrote for XP-32 works fine on W7-64 so I wonder what the problem is.  It is a little tricky to get file association working because you do not have access to your debugger since the OS kicks your application off directly when you double-click one of its data file's associated icons.  I just stumbled across how it works.  The OS puts extra double quotes around the command line.  These are not there when you call the program from a command line directly and pass it the data file's name.  If you need a source code fragment to show how to handle it, just let me know.  

jo

Hi,

We added support for double clicking TGD files in Explorer and dropping them on the application icon in TG2 Windows in v2.1.18.1. I haven't been able to check it in Windows 7 yet, but it certainly works on Vista. I'll check it out on Windows 7 when I get a chance.

Regards,

Jo

neuspadrin

Mine didn't automatically have it, but if I double clicked, it would say "open with?" then I browsed to the TG folder, picked tgd.exe, and told it to always use that.  After that double clicking tgds works.

cyphyr

Works for me too, a double click on the .tgd file icon, launches Terragen and loads the file with its associated files. I'm using win7 64 and 32bit.
Is this the question your asking?
Richard
www.richardfraservfx.com
https://www.facebook.com/RichardFraserVFX/
/|\

Ryzen 9 5950X OC@4Ghz, 64Gb (TG4 benchmark 4:13)

PabloMack

#4
I just discovered the cause of the problem.  For some reason there is a shortcut to the executable in the Terragen 2 subdirectory and I had associated the tgd file with the shortcut instead of the executable itself.  Why it causes an error, I don't know.  I created another shortcut and tried it with that one and the double-clicking worked correctly.  But if I double-click directly on the problem shortcut, it brings up TG2 normally.  Go figure.... Thanks to you all and sorry for the bother.  

jo

Hi,

Quote from: neuspadrin on April 04, 2010, 07:06:33 PM
Mine didn't automatically have it,

Yes, I should have added that you need to set up the file association yourself. That is mentioned in the change log.

Regards,

Jo