We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Help: Dynamically generate xlsm documents


I know this problem is actually a problem with Office 2007 and Internet Explorer. However, I hope I can find the answer here, since Aspose-developers hopefully have stumbled upon this before.

We are using an HttpHandler+Aspose.Cells to generate Excel-documents dynamically and send them to the client.

This has all worked fine, until our customers moved to Office 2007, and thus xlsm-files.

It turns out that with the technique we are using to create the documents, the document gets stored in Temporary Internet Files on the client's machine. (same for all Office versions)

However, from Office 2007 and on, it seems as if macros are disabled (and can't be enabled, from user consent or digital signature) if the document is stored in Temporary Internet Files. Without the macros, our solution is useless.

I have been trying to make IE not download the document to Temporary Internet Files first, but instead open it directly in Excel.
This is possible, if the url to the HttpHandler is a "real" url, e.g. `http://theserver/thedocument.xlsm`. In this case, the document is opened directly in Excel, and macros can be enabled.

However, we need to pass parameters to the HttpHandler (this determines some of the content of the Excel-file). For instance, `http://theserver/thedocument.xlsm?param1=value1&param2=value2`.
Strangely, in this case, the file gets downloaded to Temporary Internet Files first, then opened. Again, the macros are disabled.

Any advice?

Thanks! v


We think your mentioned issue is not related to Aspose.Cells (as you also pointed it out). For
confirmation, when you try to open/save an existing file using .NET File
Streams without using Aspose.Cells for .NET API, I think you will still find this issue.

Anyways, We will check it further and if we have an alternative, we will let you know.

Thank you.