How can we open an Excel sheet through the script
Answers were Sorted based on User's Feedback
Answer / uday kumar_anem
If you want to open Excel sheet using QTP, follow the below
script:
Dim objexcel
Set objExcel = createobject("Excel.application")
Set objWB = objExcel.Workbooks.Open("FileName")
Set objWS = objExcel.ActiveWorkbook.Worksheets("SheetName")
objexcel.Visible = True
Is This Answer Correct ? | 33 Yes | 4 No |
Answer / sreekanth chilam
HI All,
Try for this three ways given below :
1.
SystemUtil.Run "excelsheet path"
2.
Dim xl
Set xl=CreateObject("Excel.Application")
xl.Visible=True
xl.WorkBooks.Open "ExcelSheet path"
xl.ActiveWorkBook.Save
xl.Application.Quit
Set xl=Nothing
3.Dim xl
Set xl=CreateObject("WScript.Shell")
xl.Run "Excel.exe"
Is This Answer Correct ? | 10 Yes | 2 No |
Answer / tvsramakrishnachowdary
Hi Chandra sekhar...
Every time ur approach is abt recording...pls try to avoid
that..it will creates u prob in the real time..ok...
follow following code...
-----------------------------
set xa=createobject("excel.application")
set xb=xa.workbooks.open("d:\sample.xls")
set xs=worksheets("sheet1")
val=xs.cells(1,1).value
msgbox val
NOTE:here (1,1)--->1st row,1st column
Is This Answer Correct ? | 3 Yes | 1 No |
Answer / arv
Try this out..It worked form me.. http://www.ibm.com/developerworks/linux/library/l-pexcel/
Is This Answer Correct ? | 0 Yes | 3 No |
Answer / mukesh raghav
We can open a excel sheet from the given location.
First you write a script in ksh shell and mentioned the
actual path of the sheet and try to run your script.
Is This Answer Correct ? | 0 Yes | 5 No |
Answer / bhaskar pothuri
This question is related to automation. As an example we
can open an excel sheet in QTP using the library functions
available in the VB scripting.
Is This Answer Correct ? | 9 Yes | 16 No |
Answer / k.chandra sekhar
a) In QTP data table have two types of the Excel sheet.
b) If the extra Excel sheet wants then you create in
the data table window in QTP. This facility is possible in
QTP data table window.
c) If you want script to excel sheet then start the
record and open the one new excel sheet then stop the
record after check script. That is the script of the excel
sheet.
d) Once do this function of the excel sheet. if you
get the scripts.
My name is k.chandra sekhar,
My phone no is 09246540049,
Hyderabad.
My mail id is ndra_143@yahoo.co.in
If any body want full explain send the mail
Is This Answer Correct ? | 4 Yes | 16 No |
Answer / srikanth
InvokeApplication("C:\Documents and Settings\All
Users\Start Menu\Programs\ExcellSheet")
Is This Answer Correct ? | 1 Yes | 14 No |
Hai Friends this is Rajesh , Is there any Site or Blog that Video tutorials of Qtp that can be free downloadable to Pc. Friends if any body know that site or blog please send me because i'm really in need for that because i cannot affordMoney in learning Course in Institutes due to Financial Problem . So please Forward that Site or Blog which provides Downloadable Video Tutorials in Free to PC , As My Friend is having PC thru that I'm planning to learn. So Kindly help me Friends if you are aware of that Site/Blog
Hi,i have 3 years of experience in manual and Automation qtp.present i am searching for job in automation qtp 2Yrs,How to Explain the interviwer Roles and Responsibilites.please help me.
hi i have one issue while automating the script using QTP i want scrool down .i cannot do even using scrool down methqad is not working .the object will take WebElement plz is there any code help me
what is defination of regression testing?
why use Description programming? what is advantages and disadvantage of this methods?
can we change the name of a check point? when will you start writing testcases? do you follow any methodology for writing test scripts? qtp is key word driven testing or data driven testing?
How can we use regular expressions for a table in web page, each cell in table having unique identification, Now I want to count number of rows in table and enter data in all cells of the table?
What r the features of QTP9.2,other than QTP8.0 What r the extre features of QTP9.2.
How to run a test using quicktest professional (qtp)?
In Keyword driven frame work you have write 30 test case for one scenario,in which 10 test cases are failed while executing.client asked you to execute only the failed test cases. HOw can you execute only failed test cases
Suppose Object name was changed in the application in the second build.I have just modified the name in the Object repository as changes in the Application. Is it possible to accure changes in the script accordingly? If so Suppose I am calling the script through function, Will the changes affect in the script(which is in the function)automatically? If not affected, tell me the solution,How to handle this. How should I change the object property name while using functions
in process of project exaplnation the defects are says frequently r not?