SftMask/OCX 6.5

SftMask.UpDownPress Event

Softel vdm, Inc.

The up/down button is pressed.

Syntax       

VB.NET

Private Sub object_UpDownPress(ByVal sender As Object, ByVal e As EventArgumentType) Handles object.UpDownPress

VB

Private Sub object_UpDownPress(ByVal Up As Boolean, ByVal FieldStart As Long, ByVal FieldEnd As Long, ByVal Counter As Long, Field As String)

C#.NET

void object_UpDownPress(object sender, EventArgumentType e);

VC++

void OnUpDownPressobject(VARIANT_BOOL Up, long FieldStart, long FieldEnd, long Counter, _bstr_t* Field);

C

HRESULT OnUpDownPressobject(VARIANT_BOOL Up, long FieldStart, long FieldEnd, long Counter, BSTR* Field);

Delphi

procedure objectUpDownPress(Sender: TObject; Up : WordBool; FieldStart : Integer; FieldEnd : Integer; Counter : Integer; var Field : WideString);

object

A SftMask object.

Up

True if the upper button was pressed, usually indicating a value increment or False if the lower button was pressed.

FieldStart

The starting position of the numeric field.

FieldEnd

The length of the numeric field.

Counter

The current event counter. The event count starts at 0 when the up/down button is first pressed (or when the up/down arrow key is used). While the button (or key) remains pressed, the UpDownPress event occurs at regular intervals (every 0.1 seconds), each time the Counter value is incremented by 1. This can be used to delay additional increments or decrements by waiting until Counter reaches a certain value. It can also be used to accelerate or increase the increment used. The example below shows how this can be implemented.

Field

The contents of the numeric field as a string. The application returns a new string value in this argument. If the Field value is not modified by the application, the up/down button have no effect.

Comments

The UpDownPress event occurs when the up/down button is pressed.

The UpDownPress event only occurs for numeric fields without minimum/maximum range.

The UpDownHandled event occurs after the UpDownPress event, indicating that the control contents have been modified using the up/down button.


Feedback / comments / error reports for this topic
© 2000, 2008 - Softel vdm, Inc. - www.softelvdm.com