[Qt-interest] Qt to MS Excel

Raja Sekharan websweetweb at gmail.com
Mon Jul 27 11:16:20 CEST 2009


I used this method for web applications in the past. You could
generate an HTML table like this:

<table>
    <tr>
       <td>Name</td>
       <td>E-Mail</td
    </tr>
<tr>
     <td>Raj</td>
    <td>somet at hing.com</td>
</tr>
</table>

Save the final string as a text file with .xls file extension and open
it from microsoft excel. It opens properly in all versions of excel
including the latest one. This is what I did in the past when I needed
to export excel files from my web applications.

If not this way, you would probably need some proprietary microsoft
dlls to generate the excel file.

Raj

On Mon, Jul 27, 2009 at 11:50 AM, Ankit Agarwal<ankit17.ag at gmail.com> wrote:
> Hi,
> I have a QTableWidget with 'N' rows and 'N' columns. All the data in the
> table are either numbers or string.
> (N would vary from 20 to 300)
> My requirement is to export all these data from my application to MS Excel
> (.xls format). One way is to get all the data in a .csv file and have MS
> Excel read the .csv file and I have a Macro in MS Excel defined for the
> same. Is there some other more efficient way to do the same?
>
>
> --
> Regards,
> Ankit Agarwal
> Blog : http://ankit17.wordpress.com
>
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at trolltech.com
> http://lists.trolltech.com/mailman/listinfo/qt-interest
>
>



-- 
“Computer science education cannot make anybody an expert programmer
any more than studying brushes and pigment can make somebody an expert
painter.”




More information about the Qt-interest-old mailing list