Micro Focus QTP (UFT) Forums
Datatable.value("result","DTS")=environment("ts_result") - 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: UFT / QTP Beginners (https://www.learnqtp.com/forums/Forum-UFT-QTP-Beginners)
+--- Thread: Datatable.value("result","DTS")=environment("ts_result") (/Thread-Datatable-value-result-DTS-environment-ts-result)



Datatable.value("result","DTS")=environment("ts_result") - jaya.gudi - 10-24-2011

Hi below is my code which does not work on perticuler step where it works for all previous steps, please help with some resolution.
Scenario:
in a test case i have around 23 Steps for 1st 17 step this code works fine.when it comes to 18th step results are not updating in datatable.
Code:
ex:
Code:
strt_range=168
end_range=190
For k=strt_range to end_range
                            datatable.GetSheet("DTS").SetCurrentRow(K)
    environment("ts_result") = "Pass"
             environment("ts_err") = "Pass"
If datatable.Value("TCID","DTC") = datatable.Value("TSID","DTS") Then
       Keyword_Executor datatable.Value("Keyword","DTS")
     datatable.Value("Result","DTS") = environment("ts_result")
    'msgbox environment("ts_result")
    datatable.Value("Error","DTS") = environment("ts_err")

and it does not read remaining columns
implemented Keyword Driven Testing.
any help will be highly appreciated thanks a ton in advance.


RE: Datatable.value("result","DTS")=environment("ts_result") - Arul - 10-29-2011

Hi,
U Can try like this
Code:
datatable.Value("Result","DTS") = environment.Value("ts_result")
Arul.D