event EditChange (Itm as Item)
Occurs when the user alters the item's text box/editor field.

TypeDescription
Itm as Item An Item object that contains a editor inside.
The trial/evaluation version of the control limits firing this event. In other words, using the trial/evaluation version won't fire the event every time.

The EditChange event notifies your application once the user alters the item's editor value. The EditCaption property specifies the caption of the editor being altered. Use the AllowEdit property to add a editor inside the item, so the user can type any characters inside. The EditWidth property specifies the width of the editor inside the item. The EditBorder property specifies the border to be shown around the item's text box. You can use the Get method to collect all items of Edit type. In C++ or VFP, you can use the Notifier to get notified through the WM_COMMAND message.

Syntax for EditChange event, /NET version, on:

private void EditChange(object sender,exontrol.EXRIBBONLib.Item Itm)
{
}

Private Sub EditChange(ByVal sender As System.Object,ByVal Itm As exontrol.EXRIBBONLib.Item) Handles EditChange
End Sub

Syntax for EditChange event, /COM version, on:

private void EditChange(object sender, AxEXRIBBONLib._IRibbonEvents_EditChangeEvent e)
{
}

void OnEditChange(LPDISPATCH Itm)
{
}

void __fastcall EditChange(TObject *Sender,Exribbonlib_tlb::IItem *Itm)
{
}

procedure EditChange(ASender: TObject; Itm : IItem);
begin
end;

procedure EditChange(sender: System.Object; e: AxEXRIBBONLib._IRibbonEvents_EditChangeEvent);
begin
end;

begin event EditChange(oleobject Itm)
end event EditChange

Private Sub EditChange(ByVal sender As System.Object, ByVal e As AxEXRIBBONLib._IRibbonEvents_EditChangeEvent) Handles EditChange
End Sub

Private Sub EditChange(ByVal Itm As EXRIBBONLibCtl.IItem)
End Sub

Private Sub EditChange(ByVal Itm As Object)
End Sub

LPARAMETERS Itm

PROCEDURE OnEditChange(oRibbon,Itm)
RETURN

Syntax for EditChange event, /COM version (others), on:

<SCRIPT EVENT="EditChange(Itm)" LANGUAGE="JScript">
</SCRIPT>

<SCRIPT LANGUAGE="VBScript">
Function EditChange(Itm)
End Function
</SCRIPT>

Procedure OnComEditChange Variant llItm
	Forward Send OnComEditChange llItm
End_Procedure

METHOD OCX_EditChange(Itm) CLASS MainDialog
RETURN NIL

void onEvent_EditChange(COM _Itm)
{
}

function EditChange as v (Itm as OLE::Exontrol.Ribbon.1::IItem)
end function

function nativeObject_EditChange(Itm)
return

The following samples show how you can get notified once the user edits the field, or change the slider value:

VBA (MS Access, Excell...)

' EditChange event - Occurs when the user alters the item's text box field.
Private Sub Ribbon1_EditChange(ByVal Itm As Object)
	With Ribbon1
		Debug.Print( "EditChange event on Itm object" )
	End With
End Sub

With Ribbon1
	With .Items
		With .Add("Item")
			.AllowEdit = 3
			.EditWidth = 128
			.EditBorder = 0
			.EditValue = 25
		End With
	End With
	.Refresh 
End With

VB6

' EditChange event - Occurs when the user alters the item's text box field.
Private Sub Ribbon1_EditChange(ByVal Itm As EXRIBBONLibCtl.IItem)
	With Ribbon1
		Debug.Print( "EditChange event on Itm object" )
	End With
End Sub

With Ribbon1
	With .Items
		With .Add("Item")
			.AllowEdit = exItemEditSlider
			.EditWidth = 128
			.EditBorder = exEditBorderNone
			.EditValue = 25
		End With
	End With
	.Refresh 
End With

VB.NET

' EditChange event - Occurs when the user alters the item's text box field.
Private Sub Exribbon1_EditChange(ByVal sender As System.Object,ByVal Itm As exontrol.EXRIBBONLib.Item) Handles Exribbon1.EditChange
	With Exribbon1
		Debug.Print( "EditChange event on Itm object" )
	End With
End Sub

With Exribbon1
	With .Items
		With .Add("Item")
			.AllowEdit = exontrol.EXRIBBONLib.AllowEditEnum.exItemEditSlider
			.EditWidth = 128
			.EditBorder = exontrol.EXRIBBONLib.EditBorderEnum.exEditBorderNone
			.EditValue = 25
		End With
	End With
	.Refresh()
End With

VB.NET for /COM

' EditChange event - Occurs when the user alters the item's text box field.
Private Sub AxRibbon1_EditChange(ByVal sender As System.Object, ByVal e As AxEXRIBBONLib._IRibbonEvents_EditChangeEvent) Handles AxRibbon1.EditChange
	With AxRibbon1
		Debug.Print( "EditChange event on Itm object" )
	End With
End Sub

With AxRibbon1
	With .Items
		With .Add("Item")
			.AllowEdit = EXRIBBONLib.AllowEditEnum.exItemEditSlider
			.EditWidth = 128
			.EditBorder = EXRIBBONLib.EditBorderEnum.exEditBorderNone
			.EditValue = 25
		End With
	End With
	.Refresh()
End With

C++

// EditChange event - Occurs when the user alters the item's text box field.
void OnEditChangeRibbon1(LPDISPATCH Itm)
{
	/*
		Copy and paste the following directives to your header file as
		it defines the namespace 'EXRIBBONLib' for the library: 'ExRibbon 1.0 Control Library'
		#import <ExRibbon.dll>
		using namespace EXRIBBONLib;
	*/
	EXRIBBONLib::IRibbonPtr spRibbon1 = GetDlgItem(IDC_RIBBON1)->GetControlUnknown();
	OutputDebugStringW( L"EditChange event on Itm object" );
}

EXRIBBONLib::IRibbonPtr spRibbon1 = GetDlgItem(IDC_RIBBON1)->GetControlUnknown();
EXRIBBONLib::IItemsPtr var_Items = spRibbon1->GetItems();
	EXRIBBONLib::IItemPtr var_Item = var_Items->Add(L"Item",vtMissing,vtMissing);
		var_Item->PutAllowEdit(EXRIBBONLib::exItemEditSlider);
		var_Item->PutEditWidth(128);
		var_Item->PutEditBorder(EXRIBBONLib::exEditBorderNone);
		var_Item->PutEditValue(long(25));
spRibbon1->Refresh();

C++ Builder

// EditChange event - Occurs when the user alters the item's text box field.
void __fastcall TForm1::Ribbon1EditChange(TObject *Sender,Exribbonlib_tlb::IItem *Itm)
{
	OutputDebugString( L"EditChange event on Itm object" );
}

Exribbonlib_tlb::IItemsPtr var_Items = Ribbon1->Items;
	Exribbonlib_tlb::IItemPtr var_Item = var_Items->Add(L"Item",TNoParam(),TNoParam());
		var_Item->AllowEdit = Exribbonlib_tlb::AllowEditEnum::exItemEditSlider;
		var_Item->EditWidth = 128;
		var_Item->EditBorder = Exribbonlib_tlb::EditBorderEnum::exEditBorderNone;
		var_Item->set_EditValue(TVariant(25));
Ribbon1->Refresh();

C#

// EditChange event - Occurs when the user alters the item's text box field.
private void exribbon1_EditChange(object sender,exontrol.EXRIBBONLib.Item Itm)
{
	System.Diagnostics.Debug.Print( "EditChange event on Itm object" );
}
//this.exribbon1.EditChange += new exontrol.EXRIBBONLib.exg2antt.EditChangeEventHandler(this.exribbon1_EditChange);

exontrol.EXRIBBONLib.Items var_Items = exribbon1.Items;
	exontrol.EXRIBBONLib.Item var_Item = var_Items.Add("Item",null,null);
		var_Item.AllowEdit = exontrol.EXRIBBONLib.AllowEditEnum.exItemEditSlider;
		var_Item.EditWidth = 128;
		var_Item.EditBorder = exontrol.EXRIBBONLib.EditBorderEnum.exEditBorderNone;
		var_Item.EditValue = 25;
exribbon1.Refresh();

JScript/JavaScript

<BODY onload='Init()'>
<SCRIPT FOR="Ribbon1" EVENT="EditChange(Itm)" LANGUAGE="JScript">
	alert( "EditChange event on Itm object" );
</SCRIPT>

<OBJECT CLASSID="clsid:DDF58CFA-750F-45E0-8A00-CFBE431702E2" id="Ribbon1"></OBJECT>

<SCRIPT LANGUAGE="JScript">
function Init()
{
	var var_Items = Ribbon1.Items;
		var var_Item = var_Items.Add("Item",null,null);
			var_Item.AllowEdit = 3;
			var_Item.EditWidth = 128;
			var_Item.EditBorder = 0;
			var_Item.EditValue = 25;
	Ribbon1.Refresh();
}
</SCRIPT>
</BODY>

VBScript

<BODY onload='Init()'>
<SCRIPT LANGUAGE="VBScript">
Function Ribbon1_EditChange(Itm)
	With Ribbon1
		alert( "EditChange event on Itm object" )
	End With
End Function
</SCRIPT>

<OBJECT CLASSID="clsid:DDF58CFA-750F-45E0-8A00-CFBE431702E2" id="Ribbon1"></OBJECT>

<SCRIPT LANGUAGE="VBScript">
Function Init()
	With Ribbon1
		With .Items
			With .Add("Item")
				.AllowEdit = 3
				.EditWidth = 128
				.EditBorder = 0
				.EditValue = 25
			End With
		End With
		.Refresh 
	End With
End Function
</SCRIPT>
</BODY>

C# for /COM

// EditChange event - Occurs when the user alters the item's text box field.
private void axRibbon1_EditChange(object sender, AxEXRIBBONLib._IRibbonEvents_EditChangeEvent e)
{
	System.Diagnostics.Debug.Print( "EditChange event on Itm object" );
}
//this.axRibbon1.EditChange += new AxEXRIBBONLib._IRibbonEvents_EditChangeEventHandler(this.axRibbon1_EditChange);

EXRIBBONLib.Items var_Items = axRibbon1.Items;
	EXRIBBONLib.Item var_Item = var_Items.Add("Item",null,null);
		var_Item.AllowEdit = EXRIBBONLib.AllowEditEnum.exItemEditSlider;
		var_Item.EditWidth = 128;
		var_Item.EditBorder = EXRIBBONLib.EditBorderEnum.exEditBorderNone;
		var_Item.EditValue = 25;
axRibbon1.Refresh();

X++ (Dynamics Ax 2009)

// EditChange event - Occurs when the user alters the item's text box field.
void onEvent_EditChange(COM _Itm)
{
	;
	print( "EditChange event on Itm object" );
}

public void init()
{
	COM com_Item,com_Items;
	anytype var_Item,var_Items;
	;

	super();

	var_Items = exribbon1.Items(); com_Items = var_Items;
		var_Item = com_Items.Add("Item"); com_Item = var_Item;
			com_Item.AllowEdit(3/*exItemEditSlider*/);
			com_Item.EditWidth(128);
			com_Item.EditBorder(0/*exEditBorderNone*/);
			com_Item.EditValue(COMVariant::createFromInt(25));
	exribbon1.Refresh();
}

Delphi 8 (.NET only)

// EditChange event - Occurs when the user alters the item's text box field.
procedure TWinForm1.AxRibbon1_EditChange(sender: System.Object; e: AxEXRIBBONLib._IRibbonEvents_EditChangeEvent);
begin
	with AxRibbon1 do
	begin
		OutputDebugString( 'EditChange event on Itm object' );
	end
end;

with AxRibbon1 do
begin
	with Items do
	begin
		with Add('Item',Nil,Nil) do
		begin
			AllowEdit := EXRIBBONLib.AllowEditEnum.exItemEditSlider;
			EditWidth := 128;
			EditBorder := EXRIBBONLib.EditBorderEnum.exEditBorderNone;
			EditValue := TObject(25);
		end;
	end;
	Refresh();
end

Delphi (standard)

// EditChange event - Occurs when the user alters the item's text box field.
procedure TForm1.Ribbon1EditChange(ASender: TObject; Itm : IItem);
begin
	with Ribbon1 do
	begin
		OutputDebugString( 'EditChange event on Itm object' );
	end
end;

with Ribbon1 do
begin
	with Items do
	begin
		with Add('Item',Null,Null) do
		begin
			AllowEdit := EXRIBBONLib_TLB.exItemEditSlider;
			EditWidth := 128;
			EditBorder := EXRIBBONLib_TLB.exEditBorderNone;
			EditValue := OleVariant(25);
		end;
	end;
	Refresh();
end

VFP

*** EditChange event - Occurs when the user alters the item's text box field. ***
LPARAMETERS Itm
	with thisform.Ribbon1
		DEBUGOUT( "EditChange event on Itm object" )
	endwith

with thisform.Ribbon1
	with .Items
		with .Add("Item")
			.AllowEdit = 3
			.EditWidth = 128
			.EditBorder = 0
			.EditValue = 25
		endwith
	endwith
	.Refresh
endwith

dBASE Plus

/*
with (this.ACTIVEX1.nativeObject)
	EditChange = class::nativeObject_EditChange
endwith
*/
// Occurs when the user alters the item's text box field.
function nativeObject_EditChange(Itm)
	local oRibbon
	oRibbon = form.Activex1.nativeObject
	? "EditChange event on Itm object" 
return

local oRibbon,var_Item,var_Items

oRibbon = form.Activex1.nativeObject
var_Items = oRibbon.Items
	var_Item = var_Items.Add("Item")
		var_Item.AllowEdit = 3
		var_Item.EditWidth = 128
		var_Item.EditBorder = 0
		var_Item.EditValue = 25
oRibbon.Refresh()

XBasic (Alpha Five)

' Occurs when the user alters the item's text box field.
function EditChange as v (Itm as OLE::Exontrol.Ribbon.1::IItem)
	Dim oRibbon as P
	oRibbon = topparent:CONTROL_ACTIVEX1.activex
	? "EditChange event on Itm object" 
end function

Dim oRibbon as P
Dim var_Item as P
Dim var_Items as P

oRibbon = topparent:CONTROL_ACTIVEX1.activex
var_Items = oRibbon.Items
	var_Item = var_Items.Add("Item")
		var_Item.AllowEdit = 3
		var_Item.EditWidth = 128
		var_Item.EditBorder = 0
		var_Item.EditValue = 25
oRibbon.Refresh()

Visual Objects

METHOD OCX_Exontrol1EditChange(Itm) CLASS MainDialog
	// EditChange event - Occurs when the user alters the item's text box field.
	OutputDebugString(String2Psz( "EditChange event on Itm object" ))
RETURN NIL

local var_Item as IItem
local var_Items as IItems

var_Items := oDCOCX_Exontrol1:Items
	var_Item := var_Items:Add("Item",nil,nil)
		var_Item:AllowEdit := exItemEditSlider
		var_Item:EditWidth := 128
		var_Item:EditBorder := exEditBorderNone
		var_Item:EditValue := 25
oDCOCX_Exontrol1:Refresh()

PowerBuilder

/*begin event EditChange(oleobject Itm) - Occurs when the user alters the item's text box field.*/
/*
	OleObject oRibbon
	oRibbon = ole_1.Object
	MessageBox("Information",string( "EditChange event on Itm object" ))
*/
/*end event EditChange*/

OleObject oRibbon,var_Item,var_Items

oRibbon = ole_1.Object
var_Items = oRibbon.Items
	var_Item = var_Items.Add("Item")
		var_Item.AllowEdit = 3
		var_Item.EditWidth = 128
		var_Item.EditBorder = 0
		var_Item.EditValue = 25
oRibbon.Refresh()

Visual DataFlex

// Occurs when the user alters the item's text box field.
Procedure OnComEditChange Variant llItm
	Forward Send OnComEditChange llItm
	Showln "EditChange event on Itm object"
End_Procedure

Procedure OnCreate
	Forward Send OnCreate
	Variant voItems
	Get ComItems to voItems
	Handle hoItems
	Get Create (RefClass(cComItems)) to hoItems
	Set pvComObject of hoItems to voItems
		Variant voItem
		Get ComAdd of hoItems "Item" Nothing Nothing to voItem
		Handle hoItem
		Get Create (RefClass(cComItem)) to hoItem
		Set pvComObject of hoItem to voItem
			Set ComAllowEdit of hoItem to OLEexItemEditSlider
			Set ComEditWidth of hoItem to 128
			Set ComEditBorder of hoItem to OLEexEditBorderNone
			Set ComEditValue of hoItem to 25
		Send Destroy to hoItem
	Send Destroy to hoItems
	Send ComRefresh
End_Procedure

XBase++

PROCEDURE OnEditChange(oRibbon,Itm)
	DevOut( "EditChange event on Itm object" )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oItem
	LOCAL oItems
	LOCAL oRibbon

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oRibbon := XbpActiveXControl():new( oForm:drawingArea )
	oRibbon:CLSID  := "Exontrol.Ribbon.1" /*{DDF58CFA-750F-45E0-8A00-CFBE431702E2}*/
	oRibbon:create(,, {10,60},{610,370} )

		oRibbon:EditChange := {|Itm| OnEditChange(oRibbon,Itm)} /*Occurs when the user alters the item's text box field.*/

		oItems := oRibbon:Items()
			oItem := oItems:Add("Item")
				oItem:AllowEdit := 3/*exItemEditSlider*/
				oItem:EditWidth := 128
				oItem:EditBorder := 0/*exEditBorderNone*/
				oItem:EditValue := 25
		oRibbon:Refresh()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN