Free Support Forum - aspose.com

Problem with Aspose.Cells.GridDesktop

Hi,

I just installed Aspose Total Q3 2009 and started testing Aspose Cells with grid desktop.
I have three questions issues related to this:

  1. It seems like the version I’m using of GridDesktop does not have support for Excel 2007. This was something I believe previous versions of Apsose Grid had as quoted here: http://www.aspose.com/community/forums/thread/176497/displaying-excell.aspx . The overload discussed for ImportExcelFile with the FileFormatType.Excel2007Xlsx does not exist in version 2.0.1.34 which I’m using. I downloaded it separately subsequent to installing Total Q3. What’s the story here? If I try to use one of the other overloads opening an .xlsx file I get an exception.
  2. I’m trying to open the attached file using GridDesktop but once I open it the desktop grid freezes completely and I can’t edit anything.
  3. Why is not GridDesktop available in a dll that targets .Net 2.0?
Thanks
Bert

Hi


We are having the same issue. It appears that the grid is not responding to mouse clicks. However, once clicked, we can navigate using the keyboard. This is also a problem as the scrollbars do not display correctly, and the grid does not scroll to keep the focused cell visible.

We installed the Aspose.Grid and used the .NET 2.0 DesktopGrid and this does not appear to have the same issue. And as mentioned by Bert, we cannot find a .NET 2.0 version of the Aspose.Cells Desktop Grid.

Cheers
Paul

Thanks Paul,

I did the same thing, installed Aspose.Grid and the “freezing” went away.

I also need to make a minor correction to item 1. It appears that neither Grid.Desktop nor Cells.GridDesktop have the FileFormatType overload for Import (only for export) despite it was quoted in the post by Aspose as existing?? The import of xlsx files still doesn’t work though - I get an exception for both versions. I will update this post with an example file and the actual exception message.

Bert

EDIT:

Failing import xlsx file attached.

Exception message:

Value cannot be null.
Parameter name: entry

Stack Trace:
at Aspose.Cells.OpenXML.⨊.⨮(⩵ ⨯)
at Aspose.Cells.OpenXML.⸀.⸠(⨊ ⨈, String ⨽)
at Aspose.Cells.OpenXML.⸀.⸊()
at Aspose.Cells.OpenXML.⸀.ᯖ()
at Aspose.Cells.OpenXML.ⷾ.ⷿ(௽ ᴺ, Stream ੷)
at Aspose.Cells.௽.ప(Stream ੷, ໹ ࠾)
at Aspose.Cells.௽.ప(String ઀)
at Aspose.Grid.Desktop.GridDesktop.ImportExcelFile(String fileName)

No worries Bert.


Unfortunately switching to the Aspose.Grid is not an option for us. We only have a licence for Aspose.Cells, and so need to use the GridDesktop that came with that. I am hoping that Aspose will fix the issue, or at least bundle the .NET 2.0 version of the Grid with Aspose.Cells.

Of course, this does bring up the licencing issue (which I am still a little confused about). If we have licensed Aspose.Cells are we able to use that license for Aspose.Grid? Or is it restricted to Aspose.Cells GridDesktop?

Currently, we are using Aspose.Cells for Excel import/export routines, but there is one case in our application where the functionality of frozen cells in the grid will come in handy. Eventually, we will move this particular screen to use the GridDesktop. But if Aspose.Cells GridDesktop is broken, we can’t use it.

Hopefully this can be resolved.
Cheers
Paul

Hi,

For the issues:

1. It seems like the version I’m using of GridDesktop does not
have support for Excel 2007. This was something I believe previous
versions of Apsose Grid had as quoted here: http://www.aspose.com/community/forums/thread/176497/displaying-excell.aspx . The overload discussed for ImportExcelFile with the FileFormatType.Excel2007Xlsx does
not exist in version 2.0.1.34 which I’m using. I downloaded it
separately subsequent to installing Total Q3. What’s the story here? If
I try to use one of the other overloads opening an .xlsx file I get an
exception.

Well, it does support importing/exporting Xlsx file format. We did change the apis a bit so, if you want to open an xlsx file, you will simply write:
GridDesktop1.ImportExcelFile(@“f:\test\MyFile.xlsx”); //You don’t need to provide FileFormatType when loading the xls/xlsx file format type.
We will update the related document in the Aspose.Cells.GridDesktop documentation soon.

2. I’m trying to open the attached file using
GridDesktop but once I open it the desktop grid freezes completely and
I can’t edit anything.

Well, I tried to import/load “GridExport.xls” file to GridDesktop and it works fine, it does not freezes the grid at all and I can navigate to edit the cells fine.
Could you create a simple application to re-produce the issue, we will check it soon.
(By the way, I use Aspose.Cells.GridDesktop v2.0.1.34)

3. Why is not GridDesktop available in a dll that targets .Net 2.0?

Well, currently it is not available, we will soon provide the .NET2.0 supported version.

4. For loading/importing xlsx file issue, we found the issue and will fix it soon.

We have found the issue as you have mentioned using your xlsx file, we will figure it out and let you know about it. You issue has been logged into our issue tracking system with an issue id: CELLSNET-11717.

5. If we have licensed Aspose.Cells are we able to use that license for
Aspose.Grid? Or is it restricted to Aspose.Cells GridDesktop?

Well, I am afraid you cannot use the license issued for Aspose.Cells to work with older Aspose.Grid controls. You can only use this for Aspose.Cells library and Aspose.Cells Grid controls (Aspose.Cells.GridDesktop and Aspose.Cells.GridWeb)



Thank you.

Thanks for this Amjad,

1. OK fine with this answer.

2. I will try to reproduce it using a less involved project (using the same version as you) and post back.

3. OK fine too. Just a bit strange that you have a .net 2.0 of the older grid version but not for the ported version in cells??

4. Thanks.

5. Not an issue for me as I have a total licence but I really don’t want to use grid in production anyway. Once no. 2 is sorted this will be a non issue as far as my requirements go.

Bert

Hi Again,

Re: Number 2

Well I did a sample project with just the cells grid and it all worked fine. Seems like I have some work to do to figure out why it didn’t work in my “real” project.

I have attached my sample project in case Paul wants to have a go. It’s using 2.0.1.34 (dll in the bin\debug folder). The project does not have a licence included. It’s VS2008 SP1 and I’m running Windows 7 64 bit. The file to open is in my first post.

Back to the drawing board - at least I found one bug :slight_smile:

Thanks All!

Bert

Ah I think I see the problem. It appears the version of the Aspose.Cells.GridDesktop I am using is 2.0.1.31. This is the one that was installed using the Aspose.Cells.msi. I have not yet licenced/registered the component since I am still waiting for customer payment.


I believe that 2.0.1.34 fixes the issue. However, how do I get it? Is it available as a patch after licencing? or was that the version that was installed as part of Aspose.Total? In which case, how do I get it?

Bert, I couldn’t access your sample project. Are you able to email it to paul at sigmasix dot co dot nz? Cheers.

Paul,

I sent you the file. Also, I found 2.0.1.34 on the last post here: http://www.aspose.com/community/forums/thread/197364/value-of-1-is-not-valid-for-value-.value-should-be-between-minimum-and-maximum.aspx

Cheers…Bert

Thanks Bert. However, it didn’t solve the problem. After a couple of hours of investigation I have found it to be a very specific issue to do with the GridDesktop being contained within a TabControl that can be easily reproduced:


1. Create a new Windows Application project
2. Add a TabControl to the form
3. Add a GridDesktop to the first tab page
4. Run the application - the scrollbars will not display correctly and the grid will not respond to mouse events.

I also discovered two work-arounds:
1. Create a new Windows Application project
2. Add a TabControl to the form
3. Add a GridDesktop to the form, not the first tab page. It is important that the grid be parented to the form
4. In the constructor of the form (or Form_Load), set the grid’s Parent to the tab page (or other container that is the correct parent for the grid, in my case a Panel)
5. Run the application. The grid works as designed.

-or-

1. Create a new Windows Application project
2. Add a GridDesktop to the form
3. Add a TabControl to the form
4. Move the GridDesktop to the tab page, or other container
5. Run the application. The grid works as designed.

The issue as far as I can see is to do with the GridDesktop being parented to a TabPage within the designer. The designer-generated code adds the grid to the tab page and then sets the properties on the grid. This causes the problem. I was able to prove this by moving the designer-generated code:
this.tabPage1.Controls.Add(this.gridDesktop1);
to the end of the designer-generated code for the grid. Of course this will get overwritten next time the designer regenerates the code, hence the work-arounds. Simply add the grid to the tab page after all designer-generated code has been run.

Hope this helps somebody else as well.
Paul

Thanks Paul,

Great work. I had a small inkling that it had to do with my setup which did have the grid on a tab control page (this is an Infragistics control as a matter of interest).

So, for the Aspose people, my issue number 2 is hereby re-opened and needs to be investigated.

Regards
Bert

Hi,

Please try the attached version, this time .NET 2.0 compiled version. We have fixed the loading xlsx file issue. We could not test the issue on Win 7 64-bit. Could you try it and let us know if it works fine or not.


Thank you.

Hi Amjad


The problem with scrollbars and no mouse interactivity when contained within a TabPage still exists. Keep in mind that we have a work around for the problem, so is no longer urgent for us.

Cheers
Paul

Thanks Amjad,

The 2.0.1.2035 fix solved the xlsx import problem and it works fine on Windows 7 x64.

But as Paul said we still have the mouse problem using tab controls.

Regards
Bert


Hi,

We have fixed the bug where the two scrollbars are invisible when GridDesktop is
added into a TabControl. Please try the Aspose.Cells.GridDesktop v<st1:chsdate w:st=“on” year=“1899” month=“12” day=“30” islunardate=“False” isrocdate=“False”>2.0.1</st1:chsdate>.2036 (attached).<o:p>


Thank you.
</o:p>

Thanks Amjad,

This release (2.0.1.2036) is working fine using Windows 7 x64 and VS2008 SP1. I am happy that you have addressed the issues raised in this post (from my point of view).

Will there be a hot-fix with this version included soon?

Regards
Bert

Hi,

Will there be a hot-fix with this version included soon?

We are releasing Aspose.Cells for .NET hot fix very soon. So, you may install the installer and get the latest Aspose.Cells Grid controls from the package.

Thank you.

The issues you have found earlier (filed as 11717) have been fixed in this update.


This message was posted using Notification2Forum from Downloads module by aspose.notifier.