File path is not print in header if we create Workbook object using stream

if we load workbook object using stream and generate a tiff of it then FilePath is missing in .tiff.
And if we load workbook object using File Path and generate a tiff of it then FilePath will be print in .tiff.

Sample Code

Not Working Code
Workbook _workbook = new Workbook( File.OpenRead(@“D:\Book1.xlsx”));
_workbook.Save(@“C:\Temp\Book1.tiff”, Aspose.Cells.SaveFormat.Tiff);

Working Code
Workbook _workbook2 = new Workbook(@“D:\Book1.xlsx”);
_workbook2.Save(@“C:\Temp\Book2.tiff”, Aspose.Cells.SaveFormat.Tiff);

You can get all things in the attached zip

Cell streem load issue.zip (21.9 KB)

@hemalp,

We reproduced the issue after an initial test as you mentioned by using template file. We found File path is not printed in the header if we create Workbook object using stream.

We have opened the following new ticket(s) in our internal issue tracking system and will deliver their fixes according to the terms mentioned in Free Support Policies.

Issue ID(s): CELLSNET-53149

You can obtain Paid Support Services if you need support on a priority basis, along with the direct access to our Paid Support management team.

@hemalp
If you create Workbook object using stream,please set the file as the following codes:

Workbook _workbook = new Workbook( File.OpenRead(@“D:\Book1.xlsx”));
workbook.FileName =@“D:\Book1.xlsx”; 

Though we can get the file name from FileStream, we can not get file name from other types of stream.
So it’s better that you can set it with Workbook.FileName when creating workbook object using stream.

Ok, It’s Working fine after set value of filename.

@hemalp,
I’m glad your issue has been solved. If you have any questions, please feel free to contact us.