Page 2 of 2 <12
Topic Options
#123014 - 2004-07-16 03:30 PM Re: My shortcuts are too 'intelligent'
Richard H. Administrator Offline
Administrator
*****

Registered: 2000-01-24
Posts: 4946
Loc: Leatherhead, Surrey, UK
Ok, the good news is that this just works with the standard tools!

I tried makescut.exe, shortcut.exe and hand crafting .url links without success.

So I then thought I'd have a go at a .lnk file with a binary editor.

While browsing the ".lnk" file format information, I noticed that the file has a "relative path" already defined, which I guess it uses to find the target.

Anyhoo, I created a directory "C:\TEMP\PORT" with subdirs "BIN" and "SCRIPTS". I then created a shortcut with the target
Code:
C:\Temp\port\bin\kix32.exe scripts\myscript.kix



Editing the link file I saw that threlative path was set to ".\bin\kix32.exe" - interesting...

I moved the directory structure and the link continued to work - it automatically updated the absolute path to match the new details.

The only trick is to make sure that you specify a relative path for the script.

Top
#123015 - 2004-07-16 03:57 PM Re: My shortcuts are too 'intelligent'
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22346
Loc: OK
same thing I realized with notepad but didn't bother trying with binary editor :P
_________________________
!

download KiXnet

Top
#123016 - 2004-07-16 03:59 PM Re: My shortcuts are too 'intelligent'
Jochen Administrator Offline
KiX Supporter
*****

Registered: 2000-03-17
Posts: 6380
Loc: Stuttgart, Germany
Wow Richard,

very good call!

the target is now : "{full Path}\bin\wkix32 scripts\scriptname.kx"

StartDir is empty and the shortcut works no matter where I move the directory structure !

I would give you another vote for that if only I could

THANX

[edit: And thanx to Kent who seems to have a valid solution too which I overread at first sight]


Edited by Jochen (2004-07-16 04:01 PM)
_________________________



Top
#123017 - 2004-07-16 04:03 PM Re: My shortcuts are too 'intelligent'
Les Offline
KiX Master
*****

Registered: 2001-06-11
Posts: 12734
Loc: fortfrances.on.ca
J,
I'll give him one for you.
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.

Top
Page 2 of 2 <12


Moderator:  Arend_, Allen, Jochen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Mart 
Hop to:
Shout Box

Who's Online
0 registered and 928 anonymous users online.
Newest Members
StuTheCoder, M_Moore, BeeEm, min_seow, Audio
17884 Registered Users

Generated in 0.057 seconds in which 0.025 seconds were spent on a total of 12 queries. Zlib compression enabled.

Search the board with:
superb Board Search
or try with google:
Google
Web kixtart.org