
Doubleclick a file in Windows Explorer, start my program opening that file
Quote:
> In Windows Explorer I can associate my program (developed using
Visual Basic > 5.0 Pro in Windows95) with a file suffix.
> When I doubleclick a file with that suffix my program starts allright, but how
> can I catch the path och file name of the doubleclicked file??
Any command parameters given to your program can be accessed using VB's
"Command" function - look it up in the help.
In order for this to work, your file association data should have a "%1" after
the EXE name, eg:
C:\PROGRA~1\MYAPP\THING.EXE "%1"
The filename (and path) clicked on will be returned in %1, which can be read
using the "Command" function.
Alex Warren
http://www.*-*-*.com/ ; - Axe Software: freeware for DOS & Windows
http://www.*-*-*.com/ ;- Basix Fanzine: magazine for BASIC programmers
http://www.*-*-*.com/ ~perditionproductions - mods (IT format)
-----------------------------------------------------------------------------
(please reply to the newsgroup - if you must reply by email, change the anti-
spam rubbish to the email address above)