How to write a full path in a batch file having a folder name with space


I am writing following command in batch file

REGSVR32 E:\Documents and Settings\All Users\Application Data\xyz.dll

After running this command I am getting following error

LodLibrary(e:\Documents) failed specified module could not be found.

How can I fix this problem?

Best Solution

Put double quotes around the path that has spaces like this:

REGSVR32 "E:\Documents and Settings\All Users\Application Data\xyz.dll"