VideoBox Control

Description

The VideoBox control allows you to display video for the Vision Guide option in your forms.

Usage

You can easily display a video window on a form in your application by using the VideoBox control. When you run a vision sequence, the graphics can also be displayed on the window.

Perform the following steps to create a vision window:

  1. Place a VideoBox control on the form you want the video to be displayed.
    The control size can be changed up to the full size.
  2. Set the VideoEnabled property to True.
  3. Set the GraphicsEnabled property to True if you want to display vision graphics.
  4. By default, the Camera property value is 0.
    This allows the videobox to display video from any camera when a sequence is run. Set the Camera property to any camera number in the project to show the video and sequence graphics for that camera.

The video is automatically scaled to fit the size of the VideoBox. When you change the height or width of the videobox, the aspect ratio is maintained.

Setting VideoBox Appearance
Use the BorderStyle property to change the appearance of the videobox.

VideoBox Control Properties

Property Description
BorderStyle

The border used for the control.

Default: None

Camera

Selects which camera to display video for.

Default:

Enabled

Sets whether the control is enabled at runtime.

Default: True

EventTaskType

The type of task used for events.

Default: Normal

GraphicsEnabled

Sets whether vision graphics are displayed or not.

Default False

Height The height of the control in pixels.
Left The left coordinate of the control in pixels.
Name

The name of the control.

Default: VideoBoxXX

TabIndex The tab index of the control.
ToolTipText The text used in the control’s tooltip.
Top The top coordinate of the control in pixels.
VideoEnabled

Sets whether video is displayed on not.

Default False

Visible

Whether the control is visible or not at runtime.

Default: True

Width The width of the control in pixels.

VideoBox Control Events

Event Description
Click Executes when the user clicks the control with the mouse.
DblClick Executes when the user double clicks the control with the mouse.