1, in the assembly right-click Property2, locate the build event in the assembly properties interface in the pre-build event command line add: IF not EXIST"$ (ProjectDir): \ bin"Md"$ (ProjectDir): \ bin"IF EXIST"$ (ProjectDir): \bin\$ (TargetFileName)"Del"$ (ProjectDir): \bin\$ (TargetFileName)"IF EXIST"$ (ProjectDir): \bin\$ (TargetName). pdb"Del"$ (ProjectDir): \bin\$ (TargetName). pdb"IF EXIST"$ (ProjectDir): \bin\$ (TargetName). XML"Del"$ (ProjectDir): \bin\$ (TargetName). XML"in the post-build event command line add: XCOPY"$ (TargetPath)" "$ (ProjectDir): \ bin"/Y/D/RIF EXIST"$ (TargetDir) $ (TargetName). pdb"Xcopy"$ (TargetDir) $ (TargetName). pdb" "$ (ProjectDir): \ bin"/Y/D/RIF EXIST"$ (TargetDir) $ (TargetName). XML"Xcopy"$ (TargetDir) $ (TargetName). XML" "$ (ProjectDir): \ bin"/Y/D/R As for the parameters inside you can easily understand the following macro (specific parameters can be configured in the macro)
. NET builds DLL assemblies into the specified directory