I am using Tridion release 5.3. I am new to Tridion. Using the business connector I want to download the image files along with its XML data. My current request is as below.
<?xml version='1.0'?>
<tcmapi:Message xmlns:tcmapi="http://www.tridion.com/ContentManager/5.0/TCMAPI"
version="5.0" from="testTool" failOnError="false">
<tcmapi:Request ID="Request1" preserve="false">
<tcmapi:GetItem itemURI="tcm:6-3146" writeBinaryToDisk="true">
<tcmapi:ItemFilter type="XMLReadAll"/>
</tcmapi:GetItem>
</tcmapi:Request>
</tcmapi:Message>
What should I modify?
Don't think you can do that with Business Connector alone.
The response you get back from the GetItem request using the "writeBinaryToDisk" attribute should contain the path to where the multimedia file has been written to - usually in the Windows "Temp" folder, but you can adjust this by adding the "binaryPath" attribute. Look for:
<tcmapi:MultimediaFilename>C:\WINNT\Temp\rad5FB9C.tmp</tcmapi:MultimediaFilename>
I think you have to ensure that the account that runs Business Connector under has read/write to whatever alternative path you provide if you use this attribute though.
You then need "something" else to actually retrieve the file from the server, e.g. use the "binaryPath" to write to a folder accessible to a temporary web page and use that page to list all the files. Then you've gotta rename the file back to the original!
Last time I got close to something like this it proved to be quicker to just grab a copy of the "images" folder Tridion was publishing binaries to and go from there!
Cheers
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With