how to compare two excell sheets by using vbscript??
Answer Posted / maruthi ram
Set objExcel = CreateObject("Excel.application")
objExcel.Visible = True
Set objWorkbook1 = objExcel.workbooks.open("D:\maruthi1.xls")
Set objWorkbook2 = objExcel.workbooks.open("D:\maruthi2.xls")
Set objWorksheet1 = objWorkbook1.worksheets(1)
Set objWorksheet2 = objWorkbook2.worksheets(1)
For Each cell In objWorksheet1.UsedRange
If cell.Value <> objWorksheet2.Range(cell.Address).Value Then
msgbox "value is different"
Else
msgbox "value is same"
End If
Next
objWorkbook1.close
objWorkbook2.close
objExcel.quit
set objExcel=nothing
Is This Answer Correct ? | 6 Yes | 0 No |
Post New Answer View All Answers
What VBScript operators, functions, and statements do you use in QuickTest Professional?
Hai anyone please "Explain about Framework in QTP?"
What is file database?
What are the benefits of qtp?
What is qtpro?
explain abt dyanamic changing object with example?
X flies from Hyd to bangalore using different methods of transportation. write the test scenarios and test cases for this?
Tell some commonly used Excel VBA functions?
How many types of run modes are there in qtp?
what is the difference between the modular framework and datadriven frame work
Explain the concept of object repository & how qtp recognizes objects?
How to do the scripting. Is there any inbuilt functions in qtp as in qtp-s.
When to use shared and local object repository?
Describe the differences between functions and actions in UFT?
please any one can explain the keyword driven framework. with gmail example.