PDA

View Full Version : Install DirectX Redistributable



smh_2007
10-16-2008, 09:32 AM
Hi To All,

I could use a little assistance with the command line options for installing directx_mar2008_redist.exe.

In an install script I am using the Run Program function. The File Name is directx_mar2008_redist.exe, the Target Folder is %CURDIR%, the Command Line is /Q /T:%DXREDIST% /C and the Default Directory is %CURDIR%. I have Wait for Program, Use ShellExecuteEx and Hide Window checked. My issue is the value of %DXREDIST%. %DXREDIST% equals %CURDIR%\DX, for example if %CURDIR% = C:\Installs then %DXREDIST% = C:\Installs\DX. If there is no space in the %CURDIR% variable, then the Run Program function for installing the DirectX redistributable is fine. If there is a space for example if %CURDIR% = C:\Program Files\Installs, then the Run Program function fails. I think the command line option for DirectX can't have spaces.

Has anyone run across this issue? Does anyone have a solution?

Thanks,

Sharon

linder
10-16-2008, 10:06 AM
Sharon,

Try to put double-quotes around a long filename.

Does this help?

Friedrich

smh_2007
10-16-2008, 10:09 AM
Hi Friedrich,

I tried "/Q /T:%DXREDIT% /C" but, it failed.

How should I do it?

Thanks,

Sharon

linder
10-16-2008, 10:14 AM
Sharon,

As I understand it, you have the double-quotes around the complete argument. Windows does not allow this.

Let us assume, you know that %DXREDIT% holds a long pathname. Then Windows expects:

/Q /T:"%DXREDIT%" /C

Does this help?

Friedrich

smh_2007
10-16-2008, 10:17 AM
Hi Friedrich,

I tried that and it doesn't appear to work either. Have you tried it that way? Perhaps I'm just doing something wacky.

Thanks for the help,

Sharon

linder
10-16-2008, 10:20 AM
Sharon,

Yes, we are doing this with all command lines.

Friedrich

linder
10-16-2008, 10:22 AM
By the way, add a Display Message Box with the "command line" parameters and see what it displays at runtime.

Friedrich

smh_2007
10-16-2008, 10:26 AM
Hi Friedrich,

Thanks for the quick responses. I am currently "resetting" my test machine. I will try your suggestion again and get back to you with my results. I just want to reiterate that I am going to try to run:

Run Program %CURDIR%\directx_mar2008_redist.exe /Q /T:"%DXREDIST%" /C (Always Install) [ShellExecuteEx] [Wait]

Thanks, I'll be back in a little bit with the results. I do appreciate all your help.

Sharon

smh_2007
10-16-2008, 10:33 AM
Hi Friedrich,

Thanks for the help. That was great. I reset my machine and all was okay. I will do more testing.

Thanks,

Sharon

linder
10-16-2008, 10:36 AM
Hi Sharon,

You are very welcome :) Please keep us posted.

Friedrich