Public Class CalcExample1 Inherits System.Web.UI.Page Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Calc1.Movable = chkMovabe.Checked Calc1.CloseOnSendResult = chkSendCloses.Checked 'ensure that MonoCalculator pops for the Salary text box when the image is clicked (using *default* client side event - "onclick") Calc1.RegisterInvoker(CalcImgSalary, SalaryBox) 'ensure that MonoCalculator pops for the MonthlyCost text box when the image is double-clicked Calc1.RegisterInvoker(CalcImgCost, MonthlyCostBox, "ondblclick") 'This is what RegisterInvoker does in the Calculator's PreRender event: 'CalcImgSalary.Attributes.Add("onclick", String.Format("monoCalcExecute('{0}','{1}');", Calc1.ClientID, SalaryBox.ClientID)) 'CalcImgCost.Attributes.Add("ondblclick", String.Format("monoCalcExecute('{0}','{1}');", Calc1.ClientID, MonthlyCostBox.ClientID)) End Sub #Region " Web Form Designer Generated Code " 'This call is required by the Web Form Designer. <System.Diagnostics.DebuggerStepThrough()> Private Sub InitializeComponent() End Sub Protected WithEvents chkMovabe As System.Web.UI.WebControls.CheckBox Protected WithEvents chkSendCloses As System.Web.UI.WebControls.CheckBox Protected WithEvents SalaryLabel As System.Web.UI.WebControls.Label Protected WithEvents SalaryBox As System.Web.UI.WebControls.TextBox Protected WithEvents CalcImgSalary As System.Web.UI.WebControls.Image Protected WithEvents MonthlyCostLabel As System.Web.UI.WebControls.Label Protected WithEvents MonthlyCostBox As System.Web.UI.WebControls.TextBox Protected WithEvents CalcImgCost As System.Web.UI.WebControls.Image Protected WithEvents Calc1 As MonoSoftware.Web.Calculator.Calculator 'NOTE: The following placeholder declaration is required by the Web Form Designer. 'Do not delete or move it. Private designerPlaceholderDeclaration As System.Object Private Sub Page_Init(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Init 'CODEGEN: This method call is required by the Web Form Designer 'Do not modify it using the code editor. InitializeComponent() End Sub #End Region End Class