/// <summary> /// bind to every menuitem click event /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void FormButtonClick(object sender, EventArgs e) { if (sender is SimpleButton) { Form findForm = (sender as SimpleButton).FindForm(); if (findForm != null) { string modelName = findForm.Text; modelName += "->" + (sender as SimpleButton).Text; ApplicationCommon.WriteApplicationLogs(modelName); } } }