Re: Associate a type of file with a LV7 app
Dany Allard [EMAIL PROTECTED] wrote: Is it possible to associate a type of file, like *.txt with Notepad.exe, with a LV7 app. I know that LV7 have a new feature that permit to retrieve the command line used to call the app. But I dont think that would be useful for what I want to do. I want to Double-Click on my file and my LV7 app start automatically and the file is read and displayed. You will need the command line too! But first you need to go into the registry and create the according keys to associate your file ending with your application. Looking in the registry how things are done for instance for .vi files should give you enough of an idea. In the ROOT key you have a key .vi with its value set to some sort of name in this case LabVIEWInstrument. Under the same root group you get another group with that LabVIEWInstrument name and some groups and keys in there. The important one is shell/open/command whose value is the path to your executable and then %1 as parameter to tell the Windows shell to insert the file name the user has clicked on at this place. Then read the command line in your application and do what you need to do with it. Rolf Kalbermatter CIT Engineering Nederland BVtel: +31 (070) 415 9190 Treubstraat 7H fax: +31 (070) 415 9191 2288 EG Rijswijkhttp://www.citengineering.com Netherlands mailto:[EMAIL PROTECTED]
RE: Associate a type of file with a LV7 app
Jean-Pierre Drolet has written an article on the subject: http://openg.org/tiki/tiki-index.php?page=File+Handling+Guidelines -Jim -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Dany Allard Sent: Wednesday, February 11, 2004 8:07 AM To: [EMAIL PROTECTED] Subject: Associate a type of file with a LV7 app Hi, Is it possible to associate a type of file, like *.txt with Notepad.exe, with a LV7 app. I know that LV7 have a new feature that permit to retrieve the command line used to call the app. But I dont think that would be useful for what I want to do. I want to Double-Click on my file and my LV7 app start automatically and the file is read and displayed. Thanks Dany Allard [EMAIL PROTECTED]
Re: Associate a type of file with a LV7 app
Ha! my pet topic. Alas the solutions proposed previously won't work when LabVIEW is already running... The trick is to build a small executable and then associate the file extension to it. This small application, reads the file path from the command line and then launches LabVIEW (if necessary) and runs the appropriate VI using the VI Server. That requires the TCP VI Server be enbled on LabVIEW. The launching applications then quits and is ready for the next call. Jean-Pierre Drolet Avensys
RE: Associate a type of file with a LV7 app
yes. In windows, hold down the shift key and at the same time right click on the file. Choose open with and then set the program that you always want windows to open your file with. I hope this is the info you were looking for. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Dany Allard Sent: Wednesday, February 11, 2004 10:07 AM To: [EMAIL PROTECTED] Subject: Associate a type of file with a LV7 app Hi, Is it possible to associate a type of file, like *.txt with Notepad.exe, with a LV7 app. I know that LV7 have a new feature that permit to retrieve the command line used to call the app. But I don't think that would be useful for what I want to do. I want to Double-Click on my file and my LV7 app start automatically and the file is read and displayed. Thanks Dany Allard [EMAIL PROTECTED]