Skip to Content
author's profile photo Former Member
Former Member

From a query to an excel

OK just need somes comments or suggestions ...

On my BSP page I call a query with RSAQ_REMOTE_QUERY_CALL on an other system (I set my destination).

My result is severals lines included into my LDATA table.

So I develop this small code to convert LDATA into a HTML tab.



strlenfield = stream+PtrStr(3).

PtrStr = PtrStr + 4.

if strlenfield = 0.

FieldtoTab = '----'.


FieldtoTab = stream+PtrStr(strlenfield).


PtrStr = PtrStr + strlenfield .


<td><div align="center"><font size="2" face="Arial, Helvetica, sans-serif"><%=FieldtoTab %></font></div></td>


if stream+PtrStr(2) =';/' .






if stream+PtrStr(1) = ';'.






PtrStr = PtrStr + 1.


And I use a javascript who starts a ActiveX to create a Excel Sheet into the client machine.

So I'm not really happy. It works, but to use an activeX the user has to set Internet Browsers with uncurrent ActiveX setting.

I prefer to create a Excel into my webserver directly...

What do you thnik about it ? How write a Excel file into my WAS server ?

Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • Posted on Jun 15, 2004 at 09:43 PM

    Read this weblog to understand how to handle non-HTML stuff in BSP.

    BSP Programming: Handling Of Non-HTML Documents


    Next, do not convert the table into HTML. Convert it into CVS. This is simple text file, columns separated by commas. See previous discussion. I think a quick search on any search engine should give you enough examples of this. Or just take a spreadsheet in excel and saveAs .cvs.

    You can append the example when it works!


    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.