Free Support Forum -

Aspose Cells .NET Gridview

Thank you Amjad,

We have ran into another issue regarding images in excel. On the gridweb they do not display the same. I have attached to screenshots and excel sheet on the images in excel that differs in gridweb. (27.2 KB)


Thanks for the template file and screenshots.

I used your template file to be imported into GridWeb simply, it works fine and displays the same way as per MS Excel, see the screenshot for your reference:

I am using Aspose.Cells.GridWeb v19.9 and Google chrome browser type. Which browser type you are using? Also could you share a simple VS.NET project (runnable) to show the issue, we will check it soon.

The issues you have found earlier (filed as CELLSNET-46910) have been fixed in Aspose.Cells for .NET v19.10. This message was posted using Bugs notification tool by Amjad_Sahi

Thank You I have a question regarding cell area in grid web. Is there a way to apply dropdownlist validation to a cell area in gridweb c#? Here is the code I have:

        CellArea area = new CellArea();
        area.StartRow = 4;
        area.StartColumn = 1;
        area.EndRow = 13;
        area.EndColumn = 1;
        var validation = **area**.CreateValidation(GridValidationType.DropDownList, true);
        var values = new System.Collections.Specialized.StringCollection();
        validation.ValueList = values;

It throws an error on area

You may please give a try to the following sample code and share the feedback.

// Create Cell Area
GridWorksheet sheet = GridWeb1.WorkSheets[GridWeb1.ActiveSheetIndex];
GridCellArea ca = new GridCellArea();
ca.StartRow = 4;
ca.EndRow = 13;
ca.StartColumn = 1;
ca.EndColumn = 1;

// Get the validations collection.
var validations = sheet.Validations;
var validation = validations.Add(ca);
validation.ValidationType = GridValidationType.DropDownList;
validation.IsRequired = true;
var values = new System.Collections.Specialized.StringCollection();
validation.ValueList = values;

Thank You for that. I have ran into some other minor issues regarding the UI/Appearance being different in my GridWeb than my actual Excel Sheet

  1. Drop downs jumping to the top of the screen if Iā€™m scrolled near the bottom here is an attachment of a video showing that (1.9 MB)

  2. Another issue is that all the borders on page are not showing as the original sheet. See attachment: Borders.PNG (90.9 KB)

  3. Some images do not render correctly when imported to gridweb. See attachment for the images under the "FIXED: column. The second and fourth column is not being rendered properly. FixedImages.PNG (179.7 KB)

We can see the issues but we need to reproduce these issues here for our testing. Could you please share your template Excel file with us for our analysis? Also if some code is used other than loading the Excel file into the grid control, share that code as well.

Below is the code I am using to load the grid web and I have attached the sheet as (229.2 KB)

   private void LoadData()
        // License li = new  License();
        // li.SetLicense(@"D:\grid_project\ZZZZZZ_release_version\Aspose.Total.20141214.lic");

        // ExStart:LoadExcelFile
        // Gets the web application's path.
        string path = Server.MapPath("~");

        string fileName = path + "\\FinalSheet2.xlsm";

        // Imports from an excel file.
        // ExEnd:LoadExcelFile

        GridWeb1.EditMode = true;
        GridWeb1.SessionMode = SessionMode.Session;
        // GridWeb1.EnableAsync = true;
        GridWorksheet sheet = GridWeb1.WorkSheets[0];
        //  sheet.IsGridlinesVisible = false;
        // sheet.IsRowColumnHeadersVisible = false;
        GridWeb1.ShowHeaderBar = false;
        GridCell custNumCell = sheet.Cells["E1"];
        custNumCell.Style.Wrap = true;
        GridWeb1.WorkSheets.ActiveSheetIndex = 0;


We were able to observe the issue but we need to look into it more. We have logged the issue in our database for investigation and for a fix. Once, we will have some news for you, we will update you in this topic.

This issue has been logged as

CELLSNET-46960 ā€“ Formatting and behaviour Issues while loading Excel file to GridWeb