2 Replies Latest reply on Oct 22, 2007 5:31 PM by ntsiii

    dealing with excel in flex

    kittuokkade Level 1
      hai all,
      i want to know whether it is possible to read Excel file from a disk and display the content in datagrid.
      i also want to create a new excel with datagrid data.is this possible .how can i do this.please suggest me .

      thank you
        • 1. Re: dealing with excel in flex
          Gregory Lafrance Level 6
          There may be a simpler solution, but you could send the data from the datagrid to a server, perhaps along with a file defining how you want the Excel columns and rows formatted. Then the server can execute a Perl script using the Win32::OLE module to create the Excel file.

          You create a new Excel file like this:
          my $Excel = Win32::OLE->GetActiveObject('Excel.Application')
          || Win32::OLE->new('Excel.Application', 'Quit');

          And then you use other Win32::OLE constructs to create the rows and columns.

          This way could be quite involved though, depending on how complex you want the Excel file to be. You would also need to convert the datagrid data to csv format, which is just comma separated rows.
          • 2. Re: dealing with excel in flex
            ntsiii Level 3
            Yes, because of the security restrictions in a browser hosted Flex app, this will be quite complicated.

            But many people have discussed this, google it, I think you will find some detailed help.