hai there..this is chandu..i have a txt file which
containing 1000 lines but at a time i want to retrieve 50
lines..after 50 lines i required to retrieve 51-100..like
that i want...so could anybody help me in this...thanks in
Advance..
Answers were Sorted based on User's Feedback
Answer / king
1st of all the txt file data import into the datatable
using filesystemobject.
After completion of import the data how many rows u want u
can retrive using for loop.
you have any quarries regarding the same plz contact me or
mail me
gi_raju@hotmail.com
9823257761
| Is This Answer Correct ? | 1 Yes | 0 No |
Hi, check the Below function,
Public Function Func_ReadFromNoetpad
(str_filePath,int_frmLine,int_toLine)
Set fso = CreateObject("Scripting.FileSystemObject")
Set Notepad = fso.OpenTextFile(str_filePath,1)
int_Value = 0
Do While Notepad.AtEndOfStream <> True
getLine = Notepad.ReadLine
int_value = int_value+1
If int_Value => int_frmLine and int_Value <=
int_toLine Then
msgbox getLine
End If
Loop
Set Notepad = Nothing
End Function
Here "str_filePath" is location of the text file in
ur local machine, "int_frmLine" is for from which line u
want to get the data and "int_toLine" is for to which line
u want to get the data.
for example If u want to get the data from 20 to 30
Func_ReadFromNoetpad "C:\Documents and
Settings\sdevarapalli\Desktop\sample.txt",20,30
Note: Here i used msgbox to display the data, becoz i don't
the exact scenario what u want. If u send me what u want to
do with that i can update this function.
If any queries or concerns please mail at :
nanda.dreddy@gmail.com
| Is This Answer Correct ? | 1 Yes | 1 No |
Is there any pdf or online book for QTP Scripting? Let me know more about QTP Scripting.
How would you parameterize the text field "Country" and the same "country" when it appears as combo field on other page with text field city and same with City combo field?
How do we do DOM programming in QTP.Could you explain with an example. If possible please provide some material or link related to DOM Programming.
If you are using descriptive programming and you have two objects with the same name, so you are identiying them by name and index, how can you avoid errors if a third object with the same name is added at the begining of the page?
what is Smart identification
c language is thre but what is the purpose of c++, java is there but what is the purpose of Advanced java ....why these are all versions are coming...whta is the problem?
Does the Existing reusable action can be modified at the time of calling the action?? Please help me..
Where should we turn Smart Identification ON in QTP?
What is the difference between byref and byval in qtp?
Is there any relation between Keyword Driven Framework and Recording modes provided in QTP( whether Recording modes are applied on keyword driven framework or not?)
Explain runtime dynamic settings?
How many types of recording modes in the qtp?