ZennoLab Assemblies Documentation
MouseButtonEvent Enumeration
Example Example 
Specifies the mouse button event.
Syntax
public enum MouseButtonEvent : System.Enum 
Members
MemberDescription
ClickThe mouse click event.
DownThe mouse down event.
UpThe mouse up event.
Example
The following code example demonstrates uses of the MouseButtonEvent enumeration.
// show the save file dialog
string result = Emulator.MouseClick("Simple window", MouseButton.Left, MouseButtonEvent.Click, 200, 200);
// wait a little bit
System.Threading.Thread.Sleep(2000);
// if mouse click was successful
if (result == "ok" && !Emulator.ErrorDetected)
{
    // click on button with caption "Save"
    result = Emulator.ButtonClick("Save as", "Save");
    // make answer
    if (result == "ok" && !Emulator.ErrorDetected) return "All done";
    else return "Fail";
}
// show the save file dialog
$result = Emulator::MouseClick("Simple window", MouseButton::Left, MouseButtonEvent::Click, 200, 200);
// wait a little bit
System\Threading\Thread::Sleep(2000);
// if mouse click was successful
if ($result == "ok" && !Emulator::ErrorDetected)
{
    // click on button with caption "Save"
    $result = Emulator::ButtonClick("Save as", "Save");
    // make answer
    if ($result == "ok" && !Emulator::ErrorDetected) return "All done";
    else return "Fail";
}
Inheritance Hierarchy

System.Object
   System.ValueType
      System.Enum
         ZennoLab.Emulation.MouseButtonEvent

Requirements

Target Platforms: Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Windows Vista, Windows Server 2008 family, Windows Seven

See Also

Reference

ZennoLab.Emulation Namespace
KeyboardEvent Enumeration
MouseButton Enumeration
MouseClick Method

Send Feedback