using System; using CoreSavingLibrary; using System.Collections; using System.Configuration; using System.Data; using System.Linq; using System.Web; using System.Web.Security; using System.Web.UI; using System.Web.UI.HtmlControls; using System.Web.UI.WebControls; using System.Web.UI.WebControls.WebParts; using System.Xml.Linq; using Sybase.DataWindow; using DataLibrary; namespace Saving.Applications.shrlon.dlg { public partial class w_dlg_add_lnucfobjectrecieve : PageWebDialog, WebDialog { int i = 0; public void InitJsPostBack() { } public void WebDialogLoadBegin() { } public void CheckJsPostBack(string eventArg) { } public void WebDialogLoadEnd() { this.SetFocusScript("TextBox1"); } protected void cb_find_Click(object sender, EventArgs e) { if (i == 0) { Sdt d = WebUtil.QuerySdt("select max(loanobjective_code) as loanobjective_code from lnucfobjectrecieve "); if (d.Next()) { int g = Convert.ToInt32(d.GetString("loanobjective_code")) + 1; WebUtil.QuerySdt("insert into lnucfobjectrecieve(coop_id, loanobjective_code,loanobjective_desc) values ('" + state.SsCoopControl + "','" + g.ToString() + "','" + TextBox1.Text + "' )"); } hidden_search.Value = Request["memberno"]; hmember_no.Value = TextBox1.Text; //this.SetOnLoadedScript("SetValuetobox();"); //this.SetOnLoadedScript("SetValuetobox(\"" + Request["memberno"] + "\",\"" + TextBox1.Text + "); "); this.SetOnLoadedScript(" SetValuetobox(\"" + Request["memberno"] + "\",\"" + TextBox1.Text + "\"); "); } i = i + 1; } protected void TextBox1_TextChanged(object sender, EventArgs e) { if (i == 0) { Sdt d = WebUtil.QuerySdt("select max(loanobjective_code) as loanobjective_code from lnucfobjectrecieve "); if (d.Next()) { int g = Convert.ToInt32(d.GetString("loanobjective_code")) + 1; WebUtil.QuerySdt("insert into lnucfobjectrecieve(coop_id, loanobjective_code,loanobjective_desc) values ('" + state.SsCoopControl + "','" + g.ToString() + "','" + TextBox1.Text + "' )"); } hidden_search.Value = Request["memberno"]; hmember_no.Value = TextBox1.Text; //this.SetOnLoadedScript("SetValuetobox();"); //this.SetOnLoadedScript("SetValuetobox(\"" + Request["memberno"] + "\",\"" + TextBox1.Text + "); "); this.SetOnLoadedScript(" SetValuetobox(\"" + Request["memberno"] + "\",\"" + TextBox1.Text + "\"); "); } i = i + 1; } } }