??????QTP?У??????????????????????????κ????????Σ????????????????????????н??????????????datatable?????????б??????????????????в?????????????ж??
Dim url
url="C:Program FilesMercury InteractiveQuickTest Professionalsamplesflightappflight4a.exe"
if Dialog("text:=Login").Exist(1) then
OptionalStep.Dialog("text:=Login").WinEdit("attached text:=Agent Name:").Set DataTable("p_Text"?? dtGlobalSheet)
OptionalStep.Dialog("text:=Login").WinEdit("attached text:=Password:").Set DataTable("p_Text1"?? dtGlobalSheet)
OptionalStep.Dialog("text:=Login").WinButton("text:=OK").Click
wait(1)
else
???????QTP?????????????????????ù????
systemUtil.Run url
OptionalStep.Dialog("text:=Login").WinEdit("attached text:=Agent Name:").Set DataTable("p_Text"?? dtGlobalSheet)
OptionalStep.Dialog("text:=Login").WinEdit("attached text:=Password:").Set DataTable("p_Text1"?? dtGlobalSheet)
OptionalStep.Dialog("text:=Login").WinButton("text:=OK").Click
wait(1)
end if
????????
if Dialog("text:=Login").Dialog("text:=Flight Reservations").Exist(2)  then
dim  errorinfor??odesc
set desc=description.Create
odesc("text").value=DataTable("error"??dtGlobalSheet)
errorinfor=Dialog("text:=Login").Dialog("text:=Flight Reservations").Static(odesc).GetROProperty("text")
Dialog("text:=Login").Dialog("text:=Flight Reservations").WinButton("text:=???").Click
?????????Reporter???????÷?
Reporter.ReportEvent micDone??"????????????????????"??errorinfor
OptionalStep.Dialog("text:=Login").close
wait(1)
else
?????????????????????????????
If Window("text:=Flight Reservation").Exist(10) then
Reporter.ReportEvent micPass??"?????????"??"????????????"
Window("text:=Flight Reservation").close
wait(1)
Set desc=Nothing
end if
end if