In our application (Web based application)we will get a pdf
file and we have check a particular text in that pdf. Can
any one tell how to check text in a pdf file.
In the same pdf file it generating some links and I have to
click that links. QTP unable recognizing that links, even
id did record and playback qtp does not generating any
script.
Can any one help me….?
Answers were Sorted based on User's Feedback
Answer / ravi
In virtual object we cannt get the text what we want to
check. Plz tell how to check the text.
Is This Answer Correct ? | 2 Yes | 0 No |
Hi...we should have add in for it. but with add in also we
do it..by copieng pdf test to a text file.
for this...
string1 = "nanda"
len_data = len(string1)
i=0
file_path = "C:\Documents and Settings\Madhu
Sudhan\Desktop\pdftotext.text"
Set clipboard = createobject("mercury.clipboard")
Set fso = createobject("scripting.filesystemobject")
Set notepad = fso.createtextfile(file_path,8)
'*********Start recording click on Edit menu--select all,
'click on Edit menu--copy, click on pdf file to get deselect
'the text...************
Window("Adobe Reader").Activate
Window("Adobe Reader").WinMenu("Menu").Select "Edit;<Item 8>"
Window("Adobe Reader").WinMenu("Menu").Select "Edit;<Item 4>"
Window("Adobe Reader").Activate
get_text = clipboard.gettext
notepad.write get_text
notepad.close
set notepad = fso.opentextfile(file_path,1)
do while notepad.AtEndofStream <> true
get_data = notepad.readline
search_data = instr(get_data, "nanda")
capture_data = mid(get_data,search_data,len_data))
if capture_data = string1 then
i = i+1
else
end if
loop
msgbox "the text is found in "& i" rows"
for any queries...
nanda.dreddy@gmail.com
Is This Answer Correct ? | 2 Yes | 1 No |
Answer / pankaj
better we create instances for
learnquicktest.manipulatepdf
this can help to do operation on pdf files
Is This Answer Correct ? | 0 Yes | 0 No |
Answer / stephen
Do you have a full copy of Adobe Acrobat installed?
Is This Answer Correct ? | 0 Yes | 2 No |
Answer / sunny
haha......... it's too funny answers.........
Sorry 4 that
actually u should buy the adobe ad-in component........
correct me if I am wrong.
Is This Answer Correct ? | 0 Yes | 3 No |
Answer / swathi
I think u know it before hand.
Qtp cant recognize some objects . So we have to make that
object to be recognized by the qtp using virtual object
wizard.
Is This Answer Correct ? | 0 Yes | 4 No |
Browser("Las Vegas Hotels - Las").Page("Vegas Hotels - Hotels").Link("Luxor") ......here Luxor is a hotel and this is recognised as a link. I have many hotels like Luxor, Palms etc which are all displayed as link...How do I parametrize this by using webtable functions??? ASAP
I have to do testing for XML file using QTP. 1. I was given a sample XML, I had to edit that with my actual data and had to make a new XML-- this part is completed, I did that. 2. Now I have to copy the exact contents of that XML file and have to paste it in a web application as a request message for web appliaction processing, using QTP. So I am unable to copy and paste it in web application, please help me out.
what is clean sweep?
how can i pass a "automation script" as a parameter in a function give me need full suggestion thank inadvance
what is description object?
Explain the check points in quicktest professional?
what version of test director supports the QTP? does testdirector supports the QTP9.0?
What is quick test pro?
What is quicktest professional (qtp)?
how to know no.of mails in our g mail by using vb-script
write a script to validate the content in the web application. (do it by OR method) and (do it by Descriptive method by creating a description object.. (give a filter condition only WEbelement- not easy need to use some more property while giving filter condtions- use google for your help...))
Write the vb script for the lowest and highest values of an array?