Jump to content

setting propper associations fails in T-13


Recommended Posts

Posted

for some reason when used unattended installation with $OEM$ batch file for T-13 time

setting propper file associations fail

simple example:

for irfanview to open GIF file


ASSOC .GIF=GIF.FILE
FTYPE GIF.FILE="%PROGRAMFILES%\IrfanView\i_view32.exe" "%1"

or PDF Xchange to open PDF's


ASSOC .PDF=PDF.File
FTYPE PDF.File="%PROGRAMFILES%\PDFXChange\PDFXCView.exe" "%1"

if I do it manualy (type it in cmd window) it will work

but why doesn't it do right with T-13 batch file ?

i noticed in output window that "%1" doesn't get applied

but just "" is added which I guess screws things up

anyone know how to fix this things ?


Posted

vinifera, looks like you do not need the quotes around the %1. Help and Support (W7) shows this

assoc .pl=PerlScript 
ftype PerlScript=perl.exe %1 %*

The %* gets the parameters. Enjoy, John.

Posted

I get same result with just %1 and with %1 %*

(no quotes on both cases)

vinifera, the batch file is using the %1 as a parameter. Use %%1. You can test this simply by running the batch file in a command prompt. Enjoy, John.

Posted (edited)

hehe believe it or not I did some sniffing and found that exact answer here on MSFN :D

()

btw quotes are necessary around %'s, ive noticed on PDF file it doesn't load in PDF viewer without them

still thanks for answer, apreciate it :)

Edited by vinifera

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
  • Recently Browsing   0 members

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