How to rerieve data from .xls & compare with data in data table - Printable Version +- Micro Focus QTP (UFT) Forums (https://www.learnqtp.com/forums) +-- Forum: Micro Focus UFT (earlier known as QTP) (https://www.learnqtp.com/forums/Forum-Micro-Focus-UFT-earlier-known-as-QTP) +--- Forum: VB Scripting/Descriptive Programming (https://www.learnqtp.com/forums/Forum-VB-Scripting-Descriptive-Programming) +--- Thread: How to rerieve data from .xls & compare with data in data table (/Thread-How-to-rerieve-data-from-xls-compare-with-data-in-data-table) |
How to rerieve data from .xls & compare with data in data table - test71 - 02-20-2008 Hi Ankur, I have a basic knowledge in QTP.Right now we are learning as well as developing scripts for our application. I want to retrieve data stored in .xls sheet,first row,first colmun & compare this retrieved data with the data outputted in the data table in QTP.we are using QTP9.2.Actually the thing is,in our application,we have an 'About' box which displays the version no. of the build.I want to check whether this version no.is correct & as per latest updations in the .xls sheet from developer.So I have used output value to output this version no. in data table.Now i want to comapre the two values,one in the QTP data table & 2nd in the .xls sheet.I have tried many combinations,but all are failing. Can you please help me put in this.I am not well versed in descriptive prograaming.You can mail me at mithilasavant@gmail.com Plz do reply asap. Thanks.. RE: How to rerieve data from .xls & compare with data in data table - deepakmehta82 - 02-27-2008 Hi, You can compare it.Suppose you have an excel file called Name.xls whose path is C:\New\Name.xls.Then you can import it by writing: Code: Data Table.Import("C:\new\Name.xls") RE: How to rerieve data from .xls & compare with data in data table - test71 - 02-29-2008 Hi Deepak, Thanks for your reply.I just had a doubt in your above explaination. "Now you can use this value also and also yours local data sheet values and can compare them." ->Which is the local data sheet value?how can I get it? Actually I am using 'output value' to get the version no. from application in the run time data table.Now if I retrieve the value from .xls then will it go in the same table? i.e. run time data table? Then how can I get this version no. in local sheet? This value will change evrytime. Reg. Comaprison: can you tell me any function which will comapre these two values? Can you please send me any script regarding same. Thanks RE: How to rerieve data from .xls & compare with data in data table - test71 - 02-29-2008 Also when I use the datatable.import command & run it,it always gives me an error 'File contains a feature not supported by formula one'.I am not able to get what the error is specifying. RE: How to rerieve data from .xls & compare with data in data table - test71 - 03-07-2008 Plzzzzz....sum1 help out.... I am not getting the above problem. RE: How to rerieve data from .xls & compare with data in data table - test71 - 03-07-2008 Deepak, I was able to use the datatable.Import method & retrieve data from xls into runtime table.but how do I get the data into the local data sheet??I mean as you mentioned above? Because the data which I retrieved from xls in run time table is to be matched with the data that I will be outputting from application? Can you plz explain me how can I do this? Thanks RE: How to rerieve data from .xls & compare with data in data table - test71 - 03-10-2008 Can anyone tell me how can I compare the local sheet data with the value in run time data sheet? |