-----------------------------------------------------------

New Message on BDOTNET

-----------------------------------------------------------
From: Thepelicanbrief2
Message 1 in Discussion

Hi Folks,   I have a requirement to fullfill. I have a button on click of which I open 
up new page. Now this new page gets some data and sends it to the user using the 
response object and changing the content type.   If the user opens up the file, it 
gets opened in the same new page. This is not a problem. But if the user saves it onto 
his machine, then this blank page remains there. How do I close it? This is my current 
code   private void Page_Load(object sender, System.EventArgs e)  
{ 
// Put user code to initialize the page here 
string criteriaString = Request.QueryString["criteria"]; 
IExport ex = new ExcelServer(); 
 
SendDataToTheUser(ex.GenerateExportFile((DataSet)Session[criteriaString + 
"_DS"],(Hashtable)Session[criteriaString + "_CNV"]),ex.GetFileName);  
Page.RegisterStartupScript("closescript","<script>window.close();</Script>");  
} 
SendDataToUser will send the data to user using the response object. But this 
javascript is not getting executed. 
Please help. 
Regards, 
TBP

-----------------------------------------------------------

To stop getting this e-mail, or change how often it arrives, go to your E-mail 
Settings.
http://groups.msn.com/bdotnet/_emailsettings.msnw

Need help? If you've forgotten your password, please go to Passport Member Services.
http://groups.msn.com/_passportredir.msnw?ppmprop=help

For other questions or feedback, go to our Contact Us page.
http://groups.msn.com/contact

If you do not want to receive future e-mail from this MSN group, or if you received 
this message by mistake, please click the "Remove" link below. On the pre-addressed 
e-mail message that opens, simply click "Send". Your e-mail address will be deleted 
from this group's mailing list.
mailto:[EMAIL PROTECTED]

Reply via email to