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

Free Support Forum - aspose.com

Cannot find resource 'Aspose.Cells.SimFont.zip'

Hello, when i creat a new Workbook, this problem occured, win7

_message : System.InvalidOperationException : Cannot find resource ‘Aspose.Cells.SimFont.zip’.
_stackTrace :
在 „Ÿ..›(String )
在 e.’…ctor()
在 e.•.Š(String , FontStyle , Boolean )
在 „Ÿ.Œ.Ÿ(String , Int32 , FontStyle )
在 .‚.a‰(WorksheetCollection )
在 Aspose.Cells.WorksheetCollection.a‰()
在 Aspose.Cells.WorksheetCollection…ctor(Workbook )
在 Aspose.Cells.Workbook…ctor()

My code is
public static Workbook GetWorkbook()
return new Workbook();
private static void SetAsposeLicense()
System.Reflection.Assembly assembly = System.Reflection.Assembly.GetCallingAssembly();
System.Reflection.AssemblyName an = assembly.GetName();

using (System.IO.Stream stream = assembly.GetManifestResourceStream(an.Name + “.License.Aspose.Cells.lic”))
Aspose.Cells.License lic = new Aspose.Cells.License();
catch (System.Exception ex)
if (stream != null)

Hi Lu,

Thanks for your posting and using Aspose.Cells.

Please download and try the latest version: Aspose.Cells
for .NET v7.7.2.1
and see if it resolves your issue.

If your problem still occurs, then please provide us your sample project replicating this issue. We will look into it and update you asap.

why not contains the file “Aspose.Cells.xml” ?

Hi Lu,

Thanks for using Aspose.Cells.

This is a minor release therefore it does not contain Aspose.Cells.xml file. If you want to get this file, then please download and use the major release: Aspose.Cells for .NET 7.7.2 at your end.

Yes,the latest version solve this problem.
Thanks for your suggestions.

these three files published together?

i can't find Aspose.Cells.ltd on my pc.

Hi Lu,

Thank you for your confirmation on this.

You will find all three files (.dll, .xml & .tlb) in all sub-folders under bin folder if you have installed the Aspose.Cells for .NET API through MSI installer or have downloaded the archive containing only the assemblies from the Aspose download section. TLB file is not provided with hotfix versions such as Aspose.Cells for .NET

Please check bin folder if you have installed the API through MSI installer,
C:\Program Files (x86)\Aspose\Aspose.Cells for .NET\Bin

Thanks a lot.

Yes, i find the file Aspose.Cells.tlb.

Last question, When i published my project,must i published the file ‘Aspose.Cells.tlb’ together? What is the function of this file (Aspose.Cells.tlb) ?

In C:\Program Files\Aspose\Aspose.Cells for .NET\Bin, there two folders: “net2.0” and “net2.0_AuthenticodeSigned”, What’s the difference?

My project used .net framework 2.0, which dll i can use?

Thank you very much.

Hi Lu,

Thank you for writing back.

A type library (.tlb) is a binary file that stores information about a COM or DCOM object’s properties and methods in a form that is accessible to other applications at runtime. Using a type library, an application can determine which interfaces an object supports, and invoke an object’s interface methods. In other words, if you wish to call a .NET assembly from a COM client (like VB6), you need to first register the original component i.e; Aspose.Cells.dll using the RegAsm utility. Then a reference to type library tell the IDE what objects are COM accessible. In your scenario, you will not need the type library file.

All Aspose for .NET assemblies are signed with strong names (SNK). We use SNK to strong name an assembly and that basically ensures that Aspose DLLs can’t be swapped out with another DLL having the same name (the public keys must match in this case). Additionally, authenticode assemblies of Aspose for .NET product assemblies use a PFX. The purpose of signing them with PFX is to ensure that those DLLs haven’t been tampered. If you don’t feel the need for an “Authenticode” assembly then you should just use the ones without Authenticode.

The net2.0 folder contains assemblies to be used with .NET Framework 2.0, 3.0, 3.5, 4.0, 4.5 and Mono. This is the assembly that you should use to target .NET Framework 2.0.

Amazing. Thank you very much.

Now,I use Aspose But another problem occured.

the method Aspose.Cells.Worksheet.AutoFitRow(int rowIdx) take up most of the time. When use it, i export an excel tooks about 12 minutes, and i cut off this function, it tooks about 1.5 minutes.

My project used by 2000 users, about 30 users encountered this situation.
All of the 30 users used win7 sys.
please, help.

Hi Lu,

Thank you for writing back.

We will need a sample project from your side in order to properly analyze your recently shared scenario. Please create an archive (ZIP) of the project along with your template file (if any) before attaching it to your post.

Moreover, we have recently published a maintenance release of Aspose.Cells for .NET We would request to your please give a try to the latest build in your development environment, and share the test results here for future reference.

I used version, and fault is still there. My code like this:

// creat a new workbook and get the first worksheet
WorkSheet ws = this.GetWorkSheet();
int rowIndex;
foreach (DataRow dr in dt.rows)
// do something …

if (this.mAutoFit)

We total called the function AutoFitRow 1560 times,it tooks about 12 minutes.
If i cut off “ws.AutoFitRow(rowIndex++)”, it tooks about 1.5 minutes.


Hi Lu,

Thank you for providing the test results with latest build of Aspose.Cells for .NET API.

Unfortunately, the provided code snippet isn’t enough to evaluate the performance related issue on our end. The reason for requesting a sample application from your side is that we could replicate the exact scenario covering all routines in your original application to benchmark the performance related parameters.

Anyway, you may also opt to use the Worksheet.AutoFitRows(int startRow, int endRow) method for your requirement. Using the said method will enable you to auto fit a range of rows in a single call, thus making the overall process execute faster than your current approach.

public void AutoFitRow(int rowIndex);
public void AutoFitRow(int rowIndex, int firstColumn, int lastColumn);
public void AutoFitRow(int rowIndex, int firstColumn, int lastColumn, AutoFitterOptions options);
public void AutoFitRow(int startRow, int endRow, int startColumn, int endColumn);
public void AutoFitRows();
public void AutoFitRows(AutoFitterOptions options);
public void AutoFitRows(bool onlyAuto);
public void AutoFitRows(int startRow, int endRow);
public object CalculateFormula(string formula);

Can you show me the difference and performance of these fountions ?

Hi Lu,

Thank you for writing back.

We are working on your recently posted inquiry, and we will shortly respond back with more details in this regard.

Hi Lu,

Thank you for your patience.

Please find the details of all methods as requested,

  • AutoFitRow(int rowIndex); Auto fit a single row whose index is passed.
  • AutoFitRow(int rowIndex, int firstColumn, int lastColumn); This method auto fits a row based on content in a range of cells within the row from start column to end column.
  • AutoFitRow(int rowIndex, int firstColumn, int lastColumn, AutoFitterOptions options); This method auto fits a row based on content in a range of cells within the row from start column to end column, in respect to the AutoFitterOptions.
  • AutoFitRow(int startRow, int endRow, int startColumn, int endColumn); Auto fits row height in a rectangle range.
  • AutoFitRows(); Auto fit all rows in the worksheet.
  • AutoFitRows(AutoFitterOptions options); Auto fits all rows in the worksheet based on the AutoFitterOptions.
  • AutoFitRows(bool onlyAuto); Boolean indicates whether only fit the rows having custom height.
  • AutoFitRows(int startRow, int endRow); Auto fit a range of rows in a worksheet.
  • CalculateFormula(string formula); This method calculates a formula that is passed as a string and returns the result in an object. Formula does not have to be stored in the cell of a worksheet for this method.

Regarding the your inquiry about the performance of different AutoFitRow(s) overloads, I have executed some tests on a spreadsheet containing 1000 data rows. Most efficient method is AutoFitRow(int rowIndex) that took almost 980 milliseconds to iterate over 1000 rows to auto fit them. Second most efficient methods proved to be AutoFitRows(int startRow, int endRow) with 1238 milliseconds for same 1000 rows. All of the other overloads are taking much longer time to execute because other parameters are involved too.

Please feel free to write back in case you have further questions or concerns.

My code is very simple, and not all users have this problem.

So I think this problem may have a relationship with some PC system.
But there is no record to valid log, can you send me a loging version?


Hi Lu,

First of all, please accept my sincere apologies for not mentioning that the tests were carried out on core i7 1.73 with Windows 7 Home Premium 64-bit installed, while using the Aspose.Cells for .NET assemblies.

Providing a logging/debug assembly may not be an easy task but we can surely log a request for the development team in this regard. Firstly, we want to make sure that your source code is perfectly optimized and does not have any performance related loop holes. In order to further investigate this matter, we would request you again to please provide a copy of your application or a sample replicating your complete scenario so we could thoroughly study it on our end before suggesting any improvements. Moreover, we may also require the environment details of your server to study the behavior of your application when its deployed and serve real time requests.

If you are concerned about the privacy of your data/source code then I would like to reassure that we need such data/sample/code just to replicate a particular scenario on our end, and we delete the customer provided information/data/sample/source as soon as problem is resolved.

Hi, my brother, this is all my test code and pc info, pls test.

thank you.

may be, there is somthing wrong with “Style”.

Thanks a lot.

Hi Lu,

Thank you for providing the sample application for our review.

I have evaluated your presented scenario/project on my end, and have noticed that maximum processing time is consumed by the following code snippet where you are iterating over the cells to put the value, applying style and auto fitting rows,


Aspose.Cells.Cell cell = null;
DataRow dr;
for (int i = 0; i < 1500; i++)
dr = dt.Rows[i];
for (int j = 0; j < 10; j++)
cell = ws.Cells[i, j];

If you replace the above statements with the following code snippet, you will notice better performance with same results (attached).

//Import DataTable to the cells, starting from first cell ws.Cells.ImportDataTable(dt, false, "A1"); //Auto fit all rows in the worksheet ws.AutoFitRows(); //Create a range of cells starting from first cell up till the last cell having data in it Range range = ws.Cells.CreateRange(0, 0, ws.Cells.MaxDataRow + 1, ws.Cells.MaxDataColumn + 1); //Apply style to all cells in the range range.ApplyStyle(wb.Styles[idx], new StyleFlag() { All = true });

Please note, if you have the data in a DataTable, simplest and most efficient way is to import it using the statement Cells.ImportDataTable. Moreover, rather than iterating over all the cells to apply the style, you can create a range of all cells having data, and apply the style on each cell of the range with single call as Range.ApplyStyle.

I have attached a few snapshots of my results as well as the modified Form1.cs file (please remove the extension .txt) for your review.