Example Code

Logging Triple Mouse Clicks Using LabVIEW

Products and Environment

This section reflects the products and operating system used to create the example.

To download NI software, including the products shown below, visit ni.com/downloads.

    Software

  • LabVIEW

Code and Documents

Attachment

Download All

Overview

This example application logs triple clicks.

 

Description

This program will log Triple Clicks, but could be modified to count any number of mouse clicks. The program also uses a timeout for the clicks, so that they will be counted as a  triple click vs. three separate clicks. The last piece of functionality is the coordinates of the mouse click. These coordinations are logged and compared to the previous so that extraneous clicks are not counted as part of the triple click.

The length of the timeout, the number of clicks counted, and the pixel spacing allowed between clicks can all be changed to fit specific applications needs.

 

Requirements

  • LabVIEW 2012 (or compatible)

 

Steps to Implement or Execute Code

  1. Run the VI.
  2. Click any mouse buttons.
  3. See the results.

 

Additional Information or References VI Block Diagram

VI Block Diagram

log tripple.png

 

**This document has been updated to meet the current required format for the NI Code Exchange.**

 

 

Applications/Systems/Test
National Instruments | AWR Group

Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.