Hi,
When I am trying to import Excel sheets its allowing sheets of file with .xls extention.
When I selected files with .xlsx extention its throwing error saying "Invalid file"
My OS is Vista with QTP 9.2. Is there any constrant on the file extension?
Thanks,
Akhila
Yes it is
The .xlsx format is not supported by QTP 9.5. Try saving the excel 2007 spreadsheet as .xls and do the import
Regards
Thanks! Its working after changing the extension to .xls
Akhila
Hi All,
I am Using QTP 9.5 in Windows 7, and Windows XP.
It is accepting .xlsx files without any error.
if any issues. Please let me know.
Hi All,
I am Using QTP 9.5 in Windows 7, and Windows XP.
It is accepting .xlsx files without any error.
if any issues. Please let me know.
Hey Baba,
How did you managed to get it working? I just tried it and it does not seem to be working.
According to me, no version of QTP (including 10.0) would recognize the new MS-Office extensions(.docx, .xlsx etc.).
QTP only recognizes .xls, .doc etc. as in the MS-Office 97-2003.
I am not too sure, but from the situation presented by Baba, it appears that Windows 7 may have some settings (that should have been in place, accidentally or o.w) that can do auto backward compatibility of say .XLSX to .XLS. Some R & D on Windows 7 can be of help. - Cheers!!
-I.L
Just use below code.. and provide your desired path and run...
make sure that excel file have extension .xlsx
dim xl
set xl=createobject("excel.application")
xl.visible=true
xl.workbooks.open("E:\Baba_QTP\QTP\Data\a.xlsx")
set xl=nothing
hey Fakruddin,
you missed the original query, its not about opening an xlsx file, its about importing the sheet to datatable
which is not supported in QTP yet.
try this in QTP
Code:
Datatable.importsheet("E:\Baba_QTP\QTP\Data\a.xlsx","Sheet1","Action1")
you can also try setting the same file as datatable in Setting>Resources
let us know if any of this works.
ghdfans2010 -Many thanks for your appreciation but I dont think anyone would like to see your hair straighteners here. we all get our hair straighten automatically when at work automating different applications
Signature Included external Links which were not relevent for QTP/Testing
[Removed Signature from your profile - Saket]
everyone - Promotional/External links are not allowed here. Make sure you are posting contents which are relevent to QTP or atleast for testing.
@Saket : lol
I just saw your post today when I had to ban another spammer on this thread.