|Important||This document may not represent best practices for current development, links to downloads and other resources may no longer be valid. Current recommended version can be found here. ArchiveDisclaimer|
Occurs when a Button control is clicked within a view in a Microsoft InfoPath 2010 form.
Assembly: Microsoft.Office.Interop.InfoPath.SemiTrust (in Microsoft.Office.Interop.InfoPath.SemiTrust.dll)
In the following example, the OnClick event handler is used to show the value of my:field1 in an message box: