@Qc050.ETI
Thanks for sharing your sample code and credentials. I have tested the scenario using Aspose.Words Cloud SDK for .NET 22.1 version and your above shared template/data. However, please note I’m unable to find the referenced image file(specified in XML file) at your cloud storage. It looks like a folder name instead of an image file name.
<Img>875a0b06-2fb3-4df0-afb1-a65740be1d57</Img>
I have uploaded a sample image google.jpg to your cloud storage root updated the XML file. And used the following code for testing the mail merge API. I am still unable to replicate your reported exception. You may please check the template, data and output file in the Temp folder in your cloud storage. Please ensure that the referenced image is available on the cloud storage and has a valid file name including an extension.
string localFileName = "output.doc";
string remoteFileName = "output.doc";
string localDataFileName = "data.xml";
string remoteDataFileName = "data.xml";
string remoteFolder = "Temp";
string localFolder = @"C:\Users\hp 840 g3\Downloads\AsposeError";
//string localDataFile = File.ReadAllText(localFolder + "/data.xml");
//upload Data File
var localDataFullName = Path.Combine(localFolder, localDataFileName);
var fullNameData = Path.Combine(remoteFolder, remoteDataFileName);
var requestDataUpload = new Aspose.Words.Cloud.Sdk.Model.Requests.UploadFileRequest(System.IO.File.OpenRead(localDataFullName), fullNameData);
await wordsApi.UploadFile(requestDataUpload);
//upload Template
var localFullName = Path.Combine(localFolder, localFileName);
var fullName = Path.Combine(remoteFolder, remoteFileName);
var requestTemplateUpload = new Aspose.Words.Cloud.Sdk.Model.Requests.UploadFileRequest(System.IO.File.OpenRead(localFullName), fullName);
await wordsApi.UploadFile(requestTemplateUpload);
var request = new ExecuteMailMergeRequest(
name: remoteFileName,
mailMergeDataFile: remoteFolder + "/" + remoteDataFileName,
//data: localDataFile,
folder: remoteFolder,
withRegions: false,
cleanup: "UnusedFields",
useWholeParagraphAsRegion: false,
destFileName: "Temp/MailMerge.doc"
);
await wordsApi.ExecuteMailMerge(request);