Jump to content

Path to parent directories


Recommended Posts

Hi,

I have created a .ini file in one of my folders and - in order to give it a customised icon - I added the following line:

[.ShellClassInfo]

ConfirmFileOp=1

IconFile=..\Custom.ico

IconIndex=0

The icon Custom.ico resides in the parent folder. Thus I created a relative path using ..\ in order to link to the icon contained one level up in the hierarchy. It works just fine!

The problem is that I would like to link to an icon wich must be TWO levels up and not just one from the foder containing the .ini file. I tried to modify as follows but it did not work:

[.ShellClassInfo]

ConfirmFileOp=1

IconFile=..\..\Custom.ico

IconIndex=0

Does anyone know why ..\..\ is not the right solution? Or what am I missing in the code?

Thank you.

Link to comment
Share on other sites


Sure, it's identical to yours:

Strecture:

\bootfiles\

\bootfiles\custom.ico

\bootfiles\test\test\

\bootfiles\test\test\Desktop.ini

Contents of \bootfiles\test\test\Desktop.ini

[.ShellClassInfo]
ConfirmFileOp=1
IconFile=..\..\custom.ico
IconIndex=0

I simply used the GUI interface of XP to have the selected folder of the type "documents" then selected the icon I wanted to show, the Desktop.ini file inside the folder was:

[.ShellClassInfo]
IconFile=%SystemDrive%\bootfiles\custom.ico
IconIndex=0

I manually changed the path to the relative one and added the line that was in your example "ConfirmFileOp=1" (just to make sure it was not that part the problem).

jaclaz

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...