本文整理汇总了C#中Database.LoadDDL方法的典型用法代码示例。如果您正苦于以下问题:C# Database.LoadDDL方法的具体用法?C# Database.LoadDDL怎么用?C# Database.LoadDDL使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Database
的用法示例。
在下文中一共展示了Database.LoadDDL方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Page_Load
protected void Page_Load(object sender, EventArgs e)
{
if(!Page.IsPostBack)
{
Database db = new Database();
db.LoadDDL("FileTarget", "title", ref ddlField, "المجال");
db.LoadDDL("country", "name", ref ddlCountry, "الدولة", "lang=2");
db.LoadDDL("FileType", "Title", ref ddlType, "النوع");
string title = Request.QueryString["name"];
string date = Request.QueryString["date"];
string target = Request.QueryString["category"];
string country = Request.QueryString["country"];
string type = Request.QueryString["type"];
string no = Request.QueryString["no"];
txtTitle.Text = title;
ddlField.SelectedValue = target;
ddlCountry.SelectedValue = country;
ddlType.SelectedValue = type;
txtFileDate.Text = date;
if (no != null)
{
// string[] noArray = no.Split('/');
if (no.Length > 0)
{
txtNo1.Text = no;
}
}
LoadData(txtTitle.Text,no,ddlField.SelectedValue,txtFileDate.Text,ddlCountry.SelectedValue,ddlType.SelectedValue);
}
}
示例2: Page_Load
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
Database db = new Database();
db.LoadDDL("category","title",ref ddlCat,"ادخل فئة المعاملة","catid=1");
db.LoadDDL("category", "title", ref ddlSec, "ادخل سرية المعاملة", "catid=2");
db.LoadDDL("category", "title", ref ddlLegal, "ادخل الوضع القانوني", "catid=3");
DataTable dt = db.ExecuteDataTable("select * from document");
ddlRDoc1.Items.Add(new ListItem("اختر معاملة", "-1"));
ddlRDoc2.Items.Add(new ListItem("اختر معاملة", "-1"));
ddlRDoc3.Items.Add(new ListItem("اختر معاملة", "-1"));
ddlRDoc4.Items.Add(new ListItem("اختر معاملة", "-1"));
ddlRDoc5.Items.Add(new ListItem("اختر معاملة", "-1"));
foreach (DataRow row in dt.Rows)
{
ddlRDoc1.Items.Add(new ListItem(row["title"].ToString()+"-"+row["no"].ToString(),row["id"].ToString()));
ddlRDoc2.Items.Add(new ListItem(row["title"].ToString() + "-" + row["no"].ToString(), row["id"].ToString()));
ddlRDoc3.Items.Add(new ListItem(row["title"].ToString() + "-" + row["no"].ToString(), row["id"].ToString()));
ddlRDoc4.Items.Add(new ListItem(row["title"].ToString() + "-" + row["no"].ToString(), row["id"].ToString()));
ddlRDoc5.Items.Add(new ListItem(row["title"].ToString() + "-" + row["no"].ToString(), row["id"].ToString()));
}
if (Request.QueryString["Op"].Equals("Edit"))
{
LoadData();
}
}
}
示例3: Page_Load
protected void Page_Load(object sender, EventArgs e)
{
if(!Page.IsPostBack)
{
Database db = new Database();
// db.LoadDDL("category", "title", ref ddlField, "المجال", "catId=5");
db.LoadDDL("country", "name", ref ddlCountry, "الدولة", "lang=2");
db.LoadDDL("Filetarget", "title", ref ddlField, "المجال");
LoadData();
}
}
示例4: Page_Load
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
txtEnName.Attributes.Add("onkeydown", "if(event.which || event.keyCode){if ((event.which == 13) || (event.keyCode == 13)) {__doPostBack('" + btnSearch.UniqueID + "','');}} ");
txtEnMajor.Attributes.Add("onkeydown", "if(event.which || event.keyCode){if ((event.which == 13) || (event.keyCode == 13)) {__doPostBack('" + btnSearch.UniqueID + "','');}} ");
txtEnWork.Attributes.Add("onkeydown", "if(event.which || event.keyCode){if ((event.which == 13) || (event.keyCode == 13)) {__doPostBack('" + btnSearch.UniqueID + "','');}} ");
Database db=new Database();
Lang lang=new Lang();
ddlEnDegree.Items.Add(new ListItem(lang.getByKey("Degree"),"-1"));
ddlEnDegree.Items.Add(new ListItem(lang.getByKey("BSc"), "BSc"));
ddlEnDegree.Items.Add(new ListItem(lang.getByKey("Master"), "Master"));
ddlEnDegree.Items.Add(new ListItem(lang.getByKey("PhD"), "PhD"));
db.LoadDDL("Country",ref ddlEnCountry,lang.getByKey("Country"));
SearchResearcher("","","","","");
}
}
示例5: Page_Load
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
Database db=new Database();
Lang lang=new Lang();
db.AddParameter("@lang", lang.getCurrentLang());
db.AddParameter("@pagekey", "ContactInformation");
DataTable dt = db.ExecuteDataTable("select * from pages where [email protected] and [email protected]");
Repeater1.DataSource=dt;
Repeater1.DataBind();
db.LoadDDL("Country",ref ddlCountry,lang.getByKey("Country"));
ddlDegree.Items.Add(new ListItem(lang.getByKey("Degree"),"-1"));
ddlDegree.Items.Add(new ListItem(lang.getByKey("BSc")));
ddlDegree.Items.Add(new ListItem(lang.getByKey("Master")));
ddlDegree.Items.Add(new ListItem(lang.getByKey("PhD")));
}
}
示例6: Page_Load
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
Database db = new Database();
Lang lang = new Lang();
db.AddParameter("@lang", lang.getCurrentLang());
db.AddParameter("@key", "ContactInformation");
DataTable dt = db.ExecuteDataTable("select * from pages where [email protected] and [email protected]");
Repeater1.DataSource = dt;
Repeater1.DataBind();
db.AddParameter("@lang", lang.getCurrentLang());
db.AddParameter("@key", "MapURL");
dt = db.ExecuteDataTable("select * from pages where [email protected] and [email protected]");
Repeater2.DataSource = dt;
Repeater2.DataBind();
db.LoadDDL("Country",ref ddlCountry,lang.getByKey("Country"));
ddlTitle.Items.Add(new ListItem(lang.getByKey("Mr.")));
ddlTitle.Items.Add(new ListItem(lang.getByKey("Miss.")));
ddlTitle.Items.Add(new ListItem(lang.getByKey("Mrs.")));
}
}
示例7: Page_Load
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
Database db = new Database();
db.LoadDDL("category", "title", ref ddlField, "فئة المعاملة", "catId=1");
HyperLink3.NavigateUrl = addPage;
LoadData();
}
}
示例8: Page_Load
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
if (Request.QueryString["id"] == null) Response.Redirect("~/Default.aspx");
LoadData();
Database db=new Database();
db.LoadDDL("category","title","id",ref ddlType,"اختر سبب الابلاغ","CatId=4");
}
}
示例9: Page_Load
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
Database db = new Database();
db.LoadDDL("ResearchType", "title", ref ddlType, "التصنيف");
if (Request.QueryString["Op"].Equals("Edit"))
{
LoadData();
}
else
{
txtAddDate.Text = datets.GregToHijri(DateTime.Now.ToString("d/M/yyyy"), "d/M/yyyy");
}
}
}
示例10: Page_Load
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
Database db=new Database();
db.LoadDDL("FileTarget","title",ref ddlField,"المجال" );
HyperLink3.NavigateUrl = addPage;
LoadData();
}
}
示例11: Page_Load
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
Database db = new Database();
db.LoadDDL("country", "name", ref ddlCountry, "الدولة");
if (Request.QueryString["Op"].Equals("Edit"))
{
LoadData();
}
}
}
示例12: Page_Load
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
Database db = new Database();
db.LoadDDL("FileTarget", "title", ref ddlTarget, "اختر المجال");
db.LoadDDL("FileType","title",ref ddlType,"اختر النوع");
db.LoadDDL("FileStatus", "title", ref ddlStatus, "اختر الحالة");
db.LoadDDL("FileSecurity", "title", ref ddlSecurity, "اختر درجة السرية");
db.LoadDDL("Country", "name", ref ddlCountry, "اختر الدولة", "lang=2");
db.LoadDDL("FileField", "title", ref ddlField, "المعنين");
if (Request.QueryString["Op"].Equals("Edit"))
{
LoadData();
rowAttache.Visible = false;
}
else
{
txtFileDate.Text = datets.GregToHijri(DateTime.Now.ToString("d/M/yyyy"), "d/M/yyyy");
txtAddedDate.Text = datets.GregToHijri(DateTime.Now.ToString("d/M/yyyy"), "d/M/yyyy");
ddlCountry.SelectedValue = "2";
}
}
}
示例13: Page_Load
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
Database db = new Database();
db.LoadDDL("Researcher", "name", ref ddlResearcher, "الباحث");
if (Request.QueryString["Op"].Equals("Edit"))
{
LoadData();
}
else
{
txtAddDate.Text = _dates.GregToHijri(DateTime.Now.ToString("d/M/yyyy"));
}
listpage += "&id=" + Request.QueryString["pid"];
name += " " + db.GetProName("Researcher", "name", "id", Request.QueryString["pid"]);
ddlResearcher.SelectedValue = Request.QueryString["pid"];
}
}
示例14: Page_Load
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
Database db=new Database();
db.AddParameter("@pageKey", "ContactUs");
DataTable dt = db.ExecuteDataTable("select * from Pages where [email protected]");
if (dt.Rows.Count > 0)
{
Repeater1.DataSource = dt;
Repeater1.DataBind();
}
db.LoadDDL("Filetarget","title",ref ddlField,"المجال");
db.LoadDDL("FileType", "title", ref ddlType, "نوع الملف");
db.LoadDDL("country", "name", ref ddlCountry, "الدولة", "lang=2");
if (!t.IsUserLogin(Session))
{
mainContainerBody.Attributes["class"] += " extended";
}
else
{
Panel1.Visible = true;
}
}
}
示例15: Page_Load
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
LoadData();
Database db=new Database();
db.LoadDDL("category","title","id",ref ddlType,"اختر سبب الابلاغ","CatId=1");
}
}