1. [WIN] More Installer Questions
Howdy y'all (Again)
I've got a couple more questions for stuff I'll be tackling later on down the
road.
First of all, I'd like the user to be able to associate Euphoria files with the
interpreter, as well as whatever editor they happen to have on their system.
This would be a registry modification on the fly, allowing the user to specify
which editor the Euphoria source code will be opened with (ED, Notepad, EE,
CREdit, etc). I'm hoping there might be some Windows API code for this, as
opposed to raw manipulation of the Registry files (which I'm not prepared to
do).
The second question has to do with shortcuts. *If* the user wants, I'd like
the installer to be able to create shortcuts to whatever location the user
specifies. How would I make a shortcut?
Thanks,
Travis Beaty
Claude, Texas.
2. Re: [WIN] More Installer Questions
Travis Beaty writes
> Howdy y'all (Again)
>
> I've got a couple more questions for stuff I'll be tackling later on down
the
> road.
>
> First of all, I'd like the user to be able to associate Euphoria files
with the
> interpreter, as well as whatever editor they happen to have on their
system.
> This would be a registry modification on the fly, allowing the user to
specify
> which editor the Euphoria source code will be opened with (ED, Notepad,
EE,
> CREdit, etc). I'm hoping there might be some Windows API code for this,
as
> opposed to raw manipulation of the Registry files (which I'm not prepared
to
> do).
API :
RegCloseKey
RegConnectRegistry
RegCreateKey
RegCreateKeyEx
RegDeleteKey
RegDeleteValue
etc. etc.
Another way is create a *.reg file like this :
--- code begin
REGEDIT4
[HKEY_CLASSES_ROOT\.txt]
"Content Type"="text/plain"
@="txtfile"
[HKEY_CLASSES_ROOT\.txt\ShellNew]
"NullFile"=""
[HKEY_CLASSES_ROOT\txtfile]
@="Text documet"
[HKEY_CLASSES_ROOT\txtfile\DefaultIcon]
@="C:\\Windows\\System\\shell32.dll, -152"
[HKEY_CLASSES_ROOT\txtfile\shell]
[HKEY_CLASSES_ROOT\txtfile\shell\open]
[HKEY_CLASSES_ROOT\txtfile\shell\open\command]
@="C:\\Windows\\notepad.exe %1"
--- code end
and then open it (this example will associate *.txt with notepad.
Hope this will help,
Martin