Closed Thread
Results 1 to 6 of 6

Thread: export to excel problem with IPAddress in URL but working with localhost url

  1. #1
    mustaque is offline Newbie
    Join Date
    Apr 2008
    Posts
    3
    Rep Power
    0

    Post export to excel problem with IPAddress in URL but working with localhost url

    Hi All,

    I am getting export to excel problem when I am giving IPAddress in URL, but it is working correct when am giving localhost and page name.

    eg : when I am writing My machine IP address and aspx pagename like 192.xxx.xxx.xx/exporttoexcell.aspx then popup page is not working. the popup page is being closed automatically , and export to excel option is not comming.

    for some reason when it opens within a scripted popup (js: window.open()), it flashes and then closes immediately without any excel trigger.


    but when I am giving my machine name mustaque/exporttoexcell.aspx then popup page is working properly and export to excel is working . I am being unable to understand what may be the problem ,

    I am writing here my code

    // I am getting the value in sBody and exporting it to excel .

    string sBody = cExcel.ExportToMSExcel(true, true, 2,false, false);
    Response.Clear();

    Response.Buffer = true; Response.Charset = "";
    Response.AppendHeader("Content-Type", "application/vnd.ms-excel");

    Response.AppendHeader("Content-disposition", "attachment; filename=AcHeadMaster.xls");
    Response.Write(sBody);

    Response.End();




    please help me.

    My OS is Vista . Dotnet vn 2.0

    Thanks in Advance

    Mustaque Ahmad

    Software Engineer
    Last edited by mustaque; 04-02-2008 at 12:06 AM. Reason: update

  2. CODECALL Circuit advertisement
    Join Date
    Always
    Posts
    Many

     
  3. #2
    Join Date
    Jul 2006
    Posts
    16,494
    Blog Entries
    75
    Rep Power
    143

    Re: export to excel problem with IPAddress in URL but working with localhost url

    What browser are you using? What security settings have you set on the browser? Are you getting any messages about pages being blocked?
    Programming is a branch of mathematics.
    My CodeCall Blog | My Personal Blog

  4. #3
    mustaque is offline Newbie
    Join Date
    Apr 2008
    Posts
    3
    Rep Power
    0

    Re: export to excel problem with IPAddress in URL but working with localhost url

    Thanks for Reply

    I am using IE6 , IE7 browser. and browser setting is default. and I am not getting any message for page being blocked .

    My problem is , when I am running project throw machine name or local host and page name then popup is comming and export to excel option for save or open etc are comming

    but when I am using IP Address like 192.xxx.xxx.xx then export to excel pop up just flash on the screen and automatically closed.

    Please advice me .

    Thanks & Regards
    Mustaque

  5. #4
    Join Date
    Jul 2006
    Posts
    16,494
    Blog Entries
    75
    Rep Power
    143

    Re: export to excel problem with IPAddress in URL but working with localhost url

    I suspect your IE security settings are blocking it. Try the same experiment with a different browser (FireFox, Opera, etc). That will tell you if it's a problem with your code or your browser (IE definitely sucks).
    Programming is a branch of mathematics.
    My CodeCall Blog | My Personal Blog

  6. #5
    mustaque is offline Newbie
    Join Date
    Apr 2008
    Posts
    3
    Rep Power
    0

    Re: export to excel problem with IPAddress in URL but working with localhost url

    Thanks for Reply,

    My aplication is only applycable for IE browser.

    and the problem is comming from all IE .

    Thanks & Regards
    Mustaque

  7. #6
    rajniponugoti is offline Newbie
    Join Date
    Aug 2008
    Posts
    1
    Rep Power
    0

    Re: export to excel problem with IPAddress in URL but working with localhost url

    HI All
    I am facing a similar problem i have a aspx page which consists an Ajax Tab control

    i am just opening a pop up(which will Export data to Excel sheet) from the two tabs in two different work flows.
    it is working in Dev environment in both the work flows for ie7 .


    but in QA and other environments in one work flow it is working fine where as in the other work flow the pop opens and just disappears(both for ie6 and ie7)
    for ie6 is in all the environments it is failing.
    i tried with local host, ip address and server name in all the cases same result

    this could not be a code issue when i debug the http response through fiddler in both the cases the http response content type every thing was same and perfect.

    any help will be greatly appreciated
    Regards,
    Rajani kanth.

Closed Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Intermediate Export Datagrid to Excel
    By HighKing Scott in forum Visual Basic Tutorials
    Replies: 2
    Last Post: 06-27-2011, 10:28 AM
  2. Color datagrid export to excel
    By SimonCoder in forum Visual Basic Programming
    Replies: 0
    Last Post: 03-10-2011, 12:49 PM
  3. export image to excel
    By :-[yc]-: in forum ASP, ASP.NET and Coldfusion
    Replies: 2
    Last Post: 12-06-2010, 09:31 PM
  4. Import form Excel, filtr, export to excel
    By seatcordobawrc in forum Pascal and Delphi
    Replies: 1
    Last Post: 03-30-2010, 02:30 PM
  5. Export to excel
    By ebosysindia in forum Java Help
    Replies: 4
    Last Post: 05-18-2009, 04:42 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts