Technical documentation needed


#1

Hi,

I’m a coop student current working as a software developer at Watchfire Corp in Kanata, Canada. Watchfire makes reporting software for the automated testing of websites. Currently we’ve encountered the issue of having to install Excel on the server and client machines when customers want to export report data into excel. So I’ve decided to put together a report to compare and evaluate the different software tools out there that can resolve this issue for us. Can someone please point me to some technical documentation about how Aspose.Excel works? Some information about the architecture and various components of your software would be helpful. We are also interested in Aspose.Pdf and Aspose.Email.

Thanks.


#2

Hi Kristy,

Thanks for considering Aspose.

Have you check the documentation at http://www.aspose.com/Documentation/? And we will port our docs to our wiki system at http://www.aspose.com/wiki/Main.aspx.

You can also download the trial version at http://www.aspose.com/Downloads/. Sample code is included in those setup packages.

If you think those docs are still not enough, please post your requirements and questions here. We will provide more specific information on your questions.


#3

Hi Laurance:

I downloaded apose.excel and am trying to write the simple “Hello World” program" in C# : http://www.aspose.com/Products/Aspose.Excel/Guide/HelloWorld.html
I added a refence in Web Developer 2005 to aspose.excel, then included the line “using aspose.excel” at the top of the code-beside file (default.aspx.cs). But after I put in the line “Excel excel1 = new Excel();” and opened the new web page, I get this error:

!“ValueType mismatch”

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.BadImageFormatException: !"ValueType mismatch"

Source Error:

Line 12: public partial class Default_aspx Line 13: { Line 14: Excel excel1 = new Excel(); Line 15: } 

Source File: c:\WebSites\WebSite4\Default.aspx.cs Line: 14

Stack Trace:

[BadImageFormatException: !“ValueType mismatch”] Aspose.Excel.Record.ag.a(Int32 A_0) +0 Aspose.Excel.Worksheets.e() +635 Aspose.Excel.Worksheets…ctor() +365 Aspose.Excel.Excel…ctor() +41 Default_aspx…ctor() in c:\WebSites\WebSite4\Default.aspx.cs:14 __ASP.FastObjectFactory.Create_Default_aspx() in c:\WINNT\Microsoft.NET\Framework\v2.0.40607\Temporary ASP.NET Files\website4\59f3c4b5\f14ed83c\evmk-rn7.2.cs:0 System.Web.Compilation.BuildResultCompiledType.CreateInstanceInternal() +58 System.Web.Compilation.BuildResultCompiledType.CreateInstance() +16 System.Web.UI.PageHandlerFactory.GetHandler(HttpContext context, String requestType, String virtualPath, String path) +152 System.Web.HttpApplication.MapHttpHandler(HttpContext context, String requestType, String path, String pathTranslated, Boolean useAppConfig) +757 System.Web.MapHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +126 System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +150 

#4

I forgot to mention that I’m using the “Visual Web Developer Web Server” that’s included with Visual Web Developer, rather than IIS.
A second issue I’m having is that when I try to run one of your demos(Aspose.Excel.Demos), I get this Build error " Error 1 Build (web): It is an error to use a section registered as allowDefinition=‘MachineToApplication’ beyond application level. This error can be caused by a virtual directory not being configured as an application in IIS. C:\Program\Files\Aspose\Aspose.Excel\Demos\Aspose.Excel.Demos\Web.config 31" Can you help me please? Is there a virtual directory i have to set up on the web server?



#5

The BadImageFormatException is caused by .NET2.0. Aspose.Excel will support .NET 2.0 in about one or two weeks.

Our install msi will create virtual directory in IIS, so you may have to manually configure them in your web servers.

Please create a virtual directory named “Aspose.Excel.Demos” and point it to your folder which contains the C# demos.


#6

Thanks for the feedback Laurence. I have another question for you: How does aspose send the generate excel sheet to the client? For example, in the Hello World program, the code is “excel1.Save(“C:\HelloWorld.xsl”, FileFormatType.Default)”. This saves the excel spreadsheet on the server? When we’re talking in the sense of a web application, the code is executed on the server to generate the spreadsheet. How do you send the resulting spreadsheet to the client’s machine?


#7

Use one of the overloads of the Save method that takes an HttpResponse object as it’s final parameter.

See the on-line help (specifically the API Reference) for examples.

public void Save(
string fileName,
FileFormatType fileFormatType,
SaveType saveType,
HttpResponse response
);


#8

Laurence:

Can you let me know ASAP once Aspose supports ASP.NET 2.0? Thanks.


#9

Now it’s available. Please download and try v3.0 at http://www.aspose.com/Products/Aspose.Excel/Downloads.html.


#10

Hi Laurence:

Thanks for providing support for .Net 2.0 so fast. I’m trying to write a simple application to export data to Excel from a DataTable in ASP.NET 2.0 Beta 2.
However, when I create a new instance of the Excel object, I get an out of memory error ( all I did was put in “Excel Excel1 = new Excel()” in the Button click event handler in the aspx.cs code behind file). Invoking the garbage collector by using “System.GC.Collect()” explicitly didn’t help either. When I created Excel Application objects with the Microsoft Excel Object Model, I didn’t have this problem. Here’s the error message:

Server Error in ‘/AposeExcel’ Application.

Exception of type ‘System.OutOfMemoryException’ was thrown.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.OutOfMemoryException: Exception of type ‘System.OutOfMemoryException’ was thrown.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:

[OutOfMemoryException: Exception of type ‘System.OutOfMemoryException’ was thrown.] 


Version Information: Microsoft .NET Framework Version:2.0.50110.28; ASP.NET Version:2.0.50110.28

#11

That’s a bug in obfuscator settings and we have already fixed it. Please download and try v3.0.0.1 at http://www.aspose.com/community/files/default.aspx


#12

Hi Laurence:

I downloaded your hotfix, and replaced the Apose.Excel dll in the Bin directory. After I restarted my Visual Web Developer Web Server, I still get the same “out of memory error”. Please help!


#13

Please not only replace the dll in the bin folder, but also replace the dll in your installed Aspose.Excel folder. It’s better to find all dlls in your machine and replace them with the new dll.


#14

I did a search on my machine for “apose.excel.dll” and the only instances were in C:\websites\AposeExcel\Bin ( this is the proj I created with a refence to the dll) and C:\Program Files\Apose\Apose.Excel\Bin, ( the install directory) and My Documents\Visual Studio\Projects<b>Aspose.Excel\Backup\bin<b>Aspose.Excel
I have replaced all of them with the one from the Hot Fix. It still doesn’t work ( I even tried restarting my computer) I still get the “out of memory error”. Then I tried uninstalling everything and reinstalling, then putting in the dll in al those places again. Still the same error. :frowning:


#15

I have no problem getting Aspose.Pdf working, but can’t get Aspose.Excel to work :frowning:


#16

But another user reported this issue is resolved. Please:

1. Find another machine with .NET 2.0 but not installed Aspose.Excel before
2. Download the new hotfix at http://www.aspose.com/Products/Aspose.Excel/Fixes/Aspose.Excel.zip. It fixed some other bugs.
3. Rebuild your program in that machine.


#17

Thanks you for you speedy reply Laurence. I think maybe the problem could be caused by the fact that I’m using a CTP version of Visual Web Developer beta 2. It’s probably got some bugs in it. I will try on another machine and use beta 1 to see if it’s more stable and if the problem pessists. However, I would like to know if you’ve seen this issue before: When I move my code form the aspx.cs code behind file into a separate C# file ( so that I can put the code inside a method within class and invoke the method when I want my code to be executed), the library functions and keywords are no longer recognized by ASP.NET. It doesn’t recognize “Excel” as a type and says it is undefined. However, when the code is in the code behind file, it gets recognized properly.( I added a reference to Aspose.Excel and put in “Using Aspose.Excel”. I wonder if this is an Aspose issue, or a ASP.NET issue. Have you ever seen this issue before?


#18

We haven’t seen this problem before. But we did find that .NET 2.0 was not stable. Could you please try to write a console application? I think this issue may be caused by your IDE.


#19

It works now in VS 2005 with Aspose.Excel 3.0.4.0. Thanks! Smile