Dim username,password
Dim casecount,i
Dim currentid DataTable.ImportSheet "C:\Users\john\Desktop\william.xlsx",,"Action1"
casecount=datatable.Getsheet("Action1").GetRowCount For i = To casecount
username=DataTable("username","Action1")
password=DataTable("password","Action1")
Dialog("Login").WinEdit("Agent Name:").Set username
Dialog("Login").WinEdit("Password:").Set password
Dialog("Login").WinButton("OK").Click If Dialog("Login").Dialog("Flight Reservations").Exist() Then
ex=DataTable("ex","Action1")
ac=Dialog("Login").Dialog("Flight Reservations").Static("Please enter agent name").GetROProperty("text")
If ex=ac Then
DataTable("test","Action1")="PASS"
else
DataTable("test","Action1")="Fail"
DataTable("acresult","Action1")=ac
End If
if Dialog("Login").Dialog("Flight Reservations").WinButton("确定").Exist() Then
Dialog("Login").Dialog("Flight Reservations").WinButton("确定").Click
End if
elseif Dialog("Flight Reservations").WinButton("确定").Exist() Then
Dialog("Flight Reservations").WinButton("确定").Click
msgbox "test"
If window("Flight Reservation").Exist() Then
currentid=dataTable.GetSheet("Action1").GetCurrentRow
window("Flight Reservation").Close
If currentid=casecount Then
dataTable("test","Action1")="PASS"
else
reporter.ReportEvent micFail,"Flight","wrong user and password"
End If
else
reporter.ReportEvent micFail,"Flight","No response"
End If
End If
DataTable.GetSheet("Action1").SetNextRow
Next
DataTable.Export "C:\Users\john\Desktop\william.xlsx"
'Window("Flight Reservation").Close 'Dim casecount
'
'DataTable.ImportSheet "C:\Users\john\Desktop\william.xlsx",1,"Action1"
'casecount=datatable.Getsheet("Action1").GetRowCount
'msgbox "123 "&casecount&" dddd" 'Dialog("Login").WinButton("Cancel").Click

UFT测试本地应用程序登陆小实例(描述性编程)的更多相关文章

  1. 小程序登陆遇到 ERR_REQUEST_PARAM

    小程序测试环境突然登陆不上,返回的错误信息是{}"code":-1,"error":"ERR_REQUEST_PARAM"}. 小程序登陆代 ...

  2. 补充ABP Zero集成微信小程序登陆的BUG修复部分

    感谢园友 @turingguo 发布的 https://www.cnblogs.com/turingguo/p/9019026.html  文章,详细介绍了ABP Zero集成微信小程序登陆的实现过程 ...

  3. 第六章 “我要点爆”微信小程序云开发实例之爆文详情页制作

    爆文详情页制作 从首页中数据列表打开相应详情页面的方法: 给数据列表中每个数据项加一个点击事件,同时将当前数据项的id暂时记录在本地,然后跳转到详情页面detail goopen: function ...

  4. [小程序]微信小程序登陆并获取用户信息

    1.小程序js端调用框架登陆API,获取到一个临时code,拿着这个code去调用自己的服务端接口 2.在自己的服务器端,使用app_id app_secrect code可以获取到用户的openid ...

  5. 由于检索用户的本地应用程序数据路径时出错,导致无法生成 SQL Server 的用户实例

    /”应用程序中的服务器错误. 由于检索用户的本地应用程序数据路径时出错,导致无法生成 SQL Server 的用户实例.请确保该用户在此计算机上有本地用户配置文件.该连接将关闭. 堆栈跟踪: [Sql ...

  6. laravel5.5解决小程序登陆态的问题

    修改一个文件 : vendor\laravel\framework\src\Illuminate\Session\Middleware\StartSession.php 找到getSession()方 ...

  7. wepy开发小程序 大坑....本地调试ok,小程序上传体验版 组件出现问题

    如果你碰到的上述问题(本地调试ok,小程序上传体验版 各种莫名其妙的问题-卡死-组件属性失效-$apply()不起作用) 您需要关闭 微信开发者工具中: 1.微信开发者工具-->项目--> ...

  8. nodejs+koa+uniapp实现微信小程序登陆获取用户手机号及openId

    nodejs+koa+uniapp实现微信小程序登陆获取用户手机号及openId 前言: 我准备用nodejs+koa+uniapp实现一款餐饮点单小程序,以及nodejs+koa+vue实现后端管理 ...

  9. 微信小程序登陆流程图时序图

    微信小程序登录 小程序可以通过微信官方提供的登录能力方便地获取微信提供的用户身份标识,快速建立小程序内的用户体系. 微信小程序登录流程时序图 说明 调用 wx.login() 获取 临时登录凭证cod ...

随机推荐

  1. Exception:public class feign.codec.EncodeException feign.codec.EncodeException: 'Content-Type' cannot contain wildcard type '*'

    一.异常出现的场景  Spring Cloud 服务A通过feign调用服务B;之前是好好的,但今天突然就不好了,抛以下异常===> 出现原因补充,Spring Boot默认的JSON方式 Ja ...

  2. MySQL的自动补全和语法高亮工具MyCli

    官方地址: RHEL, Centos: We don't have packages for RHEL or Centos, yet. Instead, use pip to install mycl ...

  3. Leetcode 128 *

    class Solution { public: int longestConsecutive(vector<int>& nums) { ; unordered_map<in ...

  4. jQuery生成二维码 jquery.qrcode.js

    https://github.com/jeromeetienne/jquery-qrcode 1.将jquery.qrcode.min.js和jquery添加到您的网页中 <script src ...

  5. Maven依赖标红线,非jar包冲突问题

    Maven依赖标红线 在pom中引入依赖fastdfs-client时,该依赖可以正常引入,但是查看Maven Project时,该依赖下总是有几个依赖报红线,并不是依赖冲突,测试代码无法正常运行.想 ...

  6. 平面最近点对模板[luogu P1429]

    %:pragma GCC optimize() #include<bits/stdc++.h> #define DB double #define m (((l)+(r))>> ...

  7. 一、I/O操作(中文问题)

    一.编码概念 计算机存放数据只能存放数字,所有的字符都会被转换为不同的数字. 常见的编码有:ISO-8859-1 ASCII数字和西欧字母 GBK:简体中文和繁体,以及日文 GB2312:简体中文 B ...

  8. Utils--前台调用后台接口工具类

    Utils--前台调用后台接口工具类 package com.taotao.manage.httpclient; import java.io.IOException; import java.net ...

  9. django学习之——创建项目

    创建项目让我迷茫了会: 直接cmd 执行django-admin.py startproject  pro_name 肯定是不行的 必须cd到 D:\Program Files\Python3.3.5 ...

  10. [LeetCode] 20. Valid Parentheses ☆

    转载:https://leetcode.windliang.cc/leetCode-20-Valid%20Parentheses.html 描述 Given a string containing j ...