google搜索 站内搜索                 软件测试门户 | 软件测试培训 | 文章资料精选 | 软件测试论坛 | 测试解决方案 | 软件测试博客 | 测试招聘求职 
打印

[求助] 请问一个treeview.select的问题

请问一个treeview.select的问题


根据帮助里说的,wintreeview.select可以根据value或者index来选择,
如:wintreeview.select"xxx" 和wintreeview.select x是可以相同的,但是如果是wintreeview.select"xxx;xxx;xxx"也就是说选择的是子节点,那么如果用index的应该如何呢?
谢谢

TOP

怎么不去看 QTP的帮助呢?
实践是检验真理的唯一标准。

TOP

Description
Selects a node in the tree-view control.

Syntax
object.Select Item, [BUTTON], [Offset]

object    A test object of type WinTreeView.
Item       Required. A Variant value.

   The full path of the node to select in the tree-view control. The path is composed of the names of the nodes (with quotes) or numeric index (without quotes) separated by a semicolon. When specifying the index, the first node in a tree-view control is numbered 0.

  Note 1: If the node is identified by its full path, the default path delimiter is ';'. For example, "Root;Child1;Child2". If the default path delimiter character is used in a node name, you can change the delimiter character for your test or component using the "TreePathDelimeter" setting value. For example, Setting.Item("TreePathDelimiter") = "#"
Note 2: If the node is identified by its numeric index, QuickTest counts only the expanded nodes. Child nodes of a collapsed parent node are not counted. The first root node in a tree-view control is numbered 0.
实践是检验真理的唯一标准。

TOP

Right-click a Node in a Tree View Control


Sub Select_Example()

'The following example uses the Select method to select the node with
'the right mouse button, with an offset of 20 pixels:

Dialog("Search").WinTreeView("SysTreeView32").Select "Green", 1, 20

End Sub
实践是检验真理的唯一标准。

TOP

真是太感谢了,我查了帮助的,就是没有上面提到的关键的Note的内容,难道因为我的帮助是8.2的?sdlkfj3

TOP

 
当前时区 GMT+8, 现在时间是 2008-11-24 04:36Copyright(C)上海博为峰软件技术有限公司 2001-2007 电话:021-64471599-8017
当您在访问网站、论坛及博客过程中遇到问题时可发送email:webmaster@51testing.com或发送论坛短信至管理员风在吹