Hi,
I know that this topic has been brought up a few times in forum posts. Posting this again I am sorry, but I was not able to find the answer for what I wanted to achieve.
The other forum posts gave examples of frameworks and methods that could be used. But for my purposes that is probably overkill.
All I want to do is create an Excel spreadsheet and write values to a cell.
Can anyone give step by step instructions with code examples to help me. I've also looked at generic C# forums for this but am struggling to apply to Ranorex. I've been looking at this for 2 days and am still struggling to even create an Excel spreadsheet
ANy help or pointers would be very much appreciated.
Kind Regards
Noumaan
Creating and writing values to an Excel Sheet
Re: Creating and writing values to an Excel Sheet
Hi,
You can use the code mentioned here (to write values to existing excel file):
http://www.ranorex.com/forum/desperatel ... tml#p16024
What's not mentioned in this post is that you need to add Microsoft.Office.Interop.Excel to References...
You can use the code mentioned here (to write values to existing excel file):
http://www.ranorex.com/forum/desperatel ... tml#p16024
What's not mentioned in this post is that you need to add Microsoft.Office.Interop.Excel to References...
You do not have the required permissions to view the files attached to this post.
Pavel Kudrys
Ranorex explorer at Descartes Systems
Please add these details to your questions:
Ranorex explorer at Descartes Systems
Please add these details to your questions:
- Ranorex Snapshot. Learn how to create one >here<
- Ranorex xPath of problematic element(s)
- Ranorex version
- OS version
- HW configuration
-
- Certified Professional
- Posts: 74
- Joined: Mon Aug 14, 2006 7:17 pm
- Location: CH
Re: Creating and writing values to an Excel Sheet
Hi,
Caution: It depends against which version of Excel your are working with. With 2003 / 2007 it's ok, but if you are using 2010 / 2013, then you have to add a few more references. Otherwise you won't be able to access all the features, or methods. It also depends against which .Net Version.
And if you need help iterating trough lines and cell and writing into it, please let me know.
Regards
Dan
Caution: It depends against which version of Excel your are working with. With 2003 / 2007 it's ok, but if you are using 2010 / 2013, then you have to add a few more references. Otherwise you won't be able to access all the features, or methods. It also depends against which .Net Version.
And if you need help iterating trough lines and cell and writing into it, please let me know.
Regards
Dan
You do not have the required permissions to view the files attached to this post.
- Support Team
- Site Admin
- Posts: 12145
- Joined: Fri Jul 07, 2006 4:30 pm
- Location: Houston, Texas, USA
- Contact:
Re: Creating and writing values to an Excel Sheet
Hi,
I just want to add that it is also possible by using the Ranorex Office plugin, so there would not be a need to use the Interop DLLs. A basic and quite old explanation can be found here: Excel Test Automation Plug-In for Ranorex.
For questions, please do let us know.
Regards,
Markus
I just want to add that it is also possible by using the Ranorex Office plugin, so there would not be a need to use the Interop DLLs. A basic and quite old explanation can be found here: Excel Test Automation Plug-In for Ranorex.
For questions, please do let us know.
Regards,
Markus