Click here to Skip to main content
15,893,904 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi ,i am using web browser control in my C# application . i try to open excel file in side the browser control but its open out side the application ..can you pls give your suggestion friends...urgent.

What I have tried:

C#
public void OpenFile(string filename)
        {
            // Check the file exists
            if (!System.IO.File.Exists(filename)) throw new Exception();
            m_ExcelFileName = filename;
            // Load the workbook in the WebBrowser control
            //this.WebBrowserExcel.Navigate(filename, false);
            WebBrowserExcel.Navigate(filename, true);
        }
Posted
Updated 16-Oct-16 22:40pm
v2

1 solution

 
Share this answer
 
Comments
Member 11165784 18-Oct-16 0:45am    
HI MANO,
I TRIED BOOLEAN PARAMETER AS FALSE,THAT TIME ALSO EXCEL OPENING OUTSIDE THE APPLICATION.
1)ALSO CHANGED MY BUILD CONFIGURATION ALSO PLATFORM(ANY CPU) THAT TIME ALSO NOT WORKING...
BY,
RAJESHGANDHI

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900