Hi Everyone
I must thank the Infragistics team and also the other active members who gave me a wonderful support during my previous posts. The help provided by you all made to complete the module perfectly. I am back here with new doubts.
I have a ultrawingrid and i should import the Excel file with data to ultrawingrid. I tried with many of the codes but nothing i found to be useful. I am using Excel 2007 and Netadvantage for .NET CLR 2.0. I found something very close to what i needed but it works only for previous versions of Excel 2007. The code which i tried is below
fileLocation = OpenFileDialog.FileName;
for .NET CLR 2.0
internalWorkbook = Infragistics.Excel.Workbook.Load(fileLocation);
It stands error on the 2nd line itself with a message
The specified stream or file does not contain a valid workbook. Parameter name: fileName
I dont know where i have gone wrong. Can anyone suggest me with some of the ideas to overcome this issue and acheive Importing the data to Excel
Thanks in advance
Ferdin
What version of NetAdvantage for .NET are you using?
The ability to read an Excel 2007 file was added in NetAdvantage for .NET 2008 Volume 3. If you're using an earlier version, then this result is expected.
If you're using 2008 Volume 3, then are you referring to the "Infragistics3.Excel" assembly (rather than the Infragistics2.Excel assembly)? The Infragistics2.Excel assembly can't read an Excel 2007 format out-of-the-box. To use the Infragistics3.Excel assembly, you need to have a CLR 3.0 or CLR 3.5 application.
Vince
Thanks for your reply. I am using NetAdvantage for .NET CLR 2.0.