MakeDir/Copy not exist

Topics: Bindings File, Settings Management and SSO, Server Deployment
May 30, 2013 at 5:57 PM
I was trying to follow an example in the documentation that does the following, however elements like MakeDir and Copy no longer exist. Can anyone help or suggest an alternative?

<Target Name="CustomRedist">
<MakeDir Directories="$(RedistDir)\TestFiles" />
<!-- Force MSBuild to expand the item spec into physical file specs --> <CreateItem Include="..\TestFiles***.*">
<Output TaskParameter="Include" ItemName="TestFilesSourceGroup" />
</CreateItem>
<!-- Copy all of the files and subfolders from ..\TestFiles to $(RedistDir)\TestFiles --> <Copy DestinationFolder="$(RedistDir)\TestFiles\%(RecursiveDir)" SourceFiles="@(TestFilesSourceGroup)"/>
</Target>

Thanks,
Craig
Coordinator
May 30, 2013 at 6:18 PM
Hi Craig,

Not sure what you mean that they no longer exist. They have been part of MSBuild since the very first release.

http://msdn.microsoft.com/en-us/library/s2448zz7(v=vs.80).aspx
http://msdn.microsoft.com/en-US/library/3e54c37h(v=vs.80).aspx

What leads you to that conclusion?

Thanks,
Tom
May 30, 2013 at 6:29 PM
I'm getting the following error:
The element 'Target' in namespace 'http://schemas.microsoft.com/developer/msbuild/2003' has an invalid element 'MakeDir'..

Maybe I need a different version of MSBuild or something?

Thanks,
Craig
Coordinator
May 30, 2013 at 7:38 PM
That's Visual Studio IntelliSense, so just ignore it. It should work fine at runtime.

Thanks,
Tom
May 30, 2013 at 7:43 PM
Oh cool - thanks for helping out. A bit new to this framework.