Agent to launch Excel in browser shows HTML code

Has anyone experienced this scenario? I have a form button which executes a background agent. The agent simply loads fields into an Excel spreadsheet for the browser to display.A sample of the code:

Print {Content-Type:application/vnd.ms-excel}

Print {

}

Forall c In view.Columns

Print {<td width="80"><b>} & Cstr(c.title) & {</b></td>}

End Forall

Print {

}

Some users see the correct Excel spreadsheet displayed in the browser, and some only see the HTML code in a Viewer. These users do have ActiveX and Excel accessible by the browser (I already tested this part.) Why would the same agent not launch Excel correctly for all users? Is there some setting that needs to be changed

for these people to have the system interpret the HTML and actually launch Excel?

Any help is appreciated.

Subject: Agent to launch Excel in browser shows HTML code

Try changing then name of your agent to contain a .xls ext

http://server/db.nsf/LoadExcel.xls

lop off the ?openagent from the query string and see if that works. BTW…jake howlett has a nice article on this on his website…

http://www.codestore.net

good luck…

Mark

Subject: RE: Agent to launch Excel in browser shows HTML code

The article is very good.

I found that without the ?OpenAgent, the agent did not run at all. Our server is R6.5.3 .

Subject: RE: Agent to launch Excel in browser shows HTML code

Thanks for the input, and yes, that article is well-written and informative. Unfortunately, I am using @Command ([ToolsRunMacro])to call the agent, not a URL. Do you think it matters how the agent is called? Strange thing is that I don’t see the HTML, only my QA user does…

Subject: RE: Agent to launch Excel in browser shows HTML code

No, the method of calling the agent doesn’t matter, but your QA user’s browser setting might.

Subject: RE: Agent to launch Excel in browser shows HTML code

Do you know which setting I should have him look at? I’d like to try to duplicate his problem, or at least direct him to where to check his error. Thanks!