protected void btnCreate_Click(object sender, EventArgs e) { string strName = txtClient.Text.Trim(); string strAum = txtAum.Text.Trim(); string strWebUrl = txtWebUrl.Text.Trim(); string strLogoUrl = txtLogo.Text.Trim(); string strRank = txtRank.Text.Trim(); bool boolIsActive = chkIsActive.Checked; Guid createdBy = Guid.NewGuid(); var proxy = new BusinessProxy(); if (Id != null) { EntityClient client = proxy.GetClient(Id); proxy.UpdateClient(client.Id.ToString(), strName, strAum, strWebUrl, strLogoUrl, strRank, boolIsActive); } else { proxy.CreateClient(strName, strAum, strWebUrl, strLogoUrl, strRank, boolIsActive, createdBy); } /* * txtClient.Text = ""; * txtAum.Text = ""; * txtWebUrl.Text = ""; * txtLogo.Text = ""; * txtRank.Text = ""; * chkIsActive.Checked = true;*/ Response.Redirect("clients.aspx"); }