What might be happening (I'm not too sure how Excel interacts with the
browser) is that instead of the browser sending the data to Excel, Excel is
initiating a direct request to the webserver to retrieve the data.
The problem is that the website knows that you are logged in when using the
browser (with Session Cookies, or however you are doing it), but Excel does
not have access to those cookies and so the website does not know that the
user is logged in.
Assuming this is the case, the easiest way around it would be to make users
download the Excel file before opening it.
--
Philip Q
Microsoft MVP [ASP.NET]
"Vishal" <an*******@discussions.microsoft.com> wrote in message
news:03****************************@phx.gbl...
Hello,
I have a dataset with some content. I can convert this
dataset in a csv format which is then stored in a
stringwriter. Now I want this be open via excel, so I set
the contenttype "application/vnd.ms-excel". To access this
page the user requires to login, once the user is logged
in he can access this file. Now when this file is opened
in excel it shows me the login screen instead of the data.
The user is already logged in, so why does it show me the
login screen in excel?
Any help is appreciated.