共用方式為


Gesture.Swipe 方法 (UITestControl, UITestGestureDirection, Int32)

執行是指快速滑動簡短距離的撥動手勢。 例如,透過電子郵件的筆觸會選取它或撥動的帳戶下移並排顯示來選取它。

命名空間:  Microsoft.VisualStudio.TestTools.UITesting
組件:  Microsoft.VisualStudio.TestTools.WindowsStore.UITesting (在 Microsoft.VisualStudio.TestTools.WindowsStore.UITesting.dll 中)

語法

'宣告
Public Shared Sub Swipe ( _
    control As UITestControl, _
    swipeDirection As UITestGestureDirection, _
    swipeLength As Integer _
)
public static void Swipe(
    UITestControl control,
    UITestGestureDirection swipeDirection,
    int swipeLength
)
public:
static void Swipe(
    UITestControl^ control, 
    UITestGestureDirection swipeDirection, 
    int swipeLength
)
static member Swipe : 
        control:UITestControl * 
        swipeDirection:UITestGestureDirection * 
        swipeLength:int -> unit
public static function Swipe(
    control : UITestControl, 
    swipeDirection : UITestGestureDirection, 
    swipeLength : int
)

參數

  • swipeLength
    類型:Int32

    揮擊過的長度 (以像素為單位)。

備註

揮擊筆勢的播放取決於螢幕解析度。 如果解析度變更,參數可能必須變更。

.NET Framework 安全性

請參閱

參考

Gesture 類別

Swipe 多載

Microsoft.VisualStudio.TestTools.UITesting 命名空間