Archive: Increase Allowable File Path Length


Increase Allowable File Path Length
Hello

Is it possible to increase the file path/string length for NSIS? I am attempting to use the function FILE with a path that is rather long and I get the compile error:

File: failed opening file "..\..\..\..\12d\10.00\DPTI_Customisation\\DESIGN_12d10\DPTI_Design_User\DPTI_D_Toolbars\DPTI_D_Create_D_Boundaries_for_Tin.slx"
Is it possible to increase the allowable length like how you can increase the $NSIS_MAX_STRLEN varaible length?

This thread says that the error is caused by the file path being too long.

That path on its own is only 126 characters (NSIS_MAX_STRLEN is 1024) so I'll assume it may be too long after combining the current script directory plus that given path. How long is the path for your script?

If the combined path is over 1024 characters you can either try moving the script to a shorter path or use the NSIS longer strings special build: http://nsis.sf.net/Special_Builds.

Stu


Thanks Afrow UK :)

Gonna give the special build a go.


the special build should have no effect in this situation. as it's an issue during compile, then the path needs to be re-checked to make sure that it's being done in the correct relative form (or use an absolute path). as unless you're using unc paths, you're going to be limited to 260 character path lengths which is why the special build will have no effect and points at the path being wrong.