当前位置: 首页>>代码示例>>C#>>正文


C# Whitfieldcore.GetSchedule方法代码示例

本文整理汇总了C#中Whitfieldcore.GetSchedule方法的典型用法代码示例。如果您正苦于以下问题:C# Whitfieldcore.GetSchedule方法的具体用法?C# Whitfieldcore.GetSchedule怎么用?C# Whitfieldcore.GetSchedule使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Whitfieldcore的用法示例。


在下文中一共展示了Whitfieldcore.GetSchedule方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: Page_Load

    protected void Page_Load(object sender, EventArgs e)
    {
        Whitfieldcore wc = new Whitfieldcore();
        if (!Page.IsPostBack)
        {
            DataSet ds = new DataSet();
            ds = wc.GetSchedule("01/01/2010", "08/01/2010");
            Int32 resultCount = 0;

            if (ds.Tables.Count > 0)
                resultCount = ds.Tables[0].Rows.Count;

            DataTable myControls;
            myControls = ds.Tables[0];
            Int32 iCnt = 1;
            if (myControls.Rows.Count > 0)
            {
                try
                {
                    foreach (DataRow dRow in myControls.Rows)
                    {
                        Hashtable hash = wc.GetWeeksHash();
                        String _yr = dRow["dt2"] != DBNull.Value ? dRow["dt2"].ToString() : "";
                        String _mnth = dRow["dt1"] != DBNull.Value ? dRow["dt1"].ToString() : "";
                        foreach (string key in hash.Keys)
                        {
                            //+ '(' + [fycd] + ')'
                            wc.PopulateSchedule(1, _yr, _mnth + "(" + _yr + ")", hash[key].ToString(),iCnt,"0");
                            //passs
                            //_yr
                            //_mnth
                            //hash[key].ToString()
                            //ProjectNumber to the Maintainschedule
                        }
                        iCnt++;
                    }
                    Response.Write("setup Completed.");
                }
                catch (Exception ex)
                {
                    Response.Write(ex.Message);
                }
            }
            else
            {
                Response.Write("No Data");

            }

        }
    }
开发者ID:frdharish,项目名称:WhitfieldAPPs,代码行数:51,代码来源:production_schedule.aspx.cs

示例2: btnProdSchedule_Click

 protected void btnProdSchedule_Click(object sender, EventArgs e)
 {
     Whitfieldcore wc = new Whitfieldcore();
     DataSet ds = new DataSet();
     if (!ViewState["Construction_Start_Date"].ToString().Equals("") && !ViewState["Construction_End_Date"].ToString().Equals(""))
     {
         ds = wc.GetSchedule(ViewState["Construction_Start_Date"].ToString(), ViewState["Construction_End_Date"].ToString());
         Int32 resultCount = 0;
         if (ds.Tables.Count > 0)
             resultCount = ds.Tables[0].Rows.Count;
         DataTable myControls;
         myControls = ds.Tables[0];
         Int32 iCnt = 1;
         if (myControls.Rows.Count > 0)
         {
             try
             {
                 foreach (DataRow dRow in myControls.Rows)
                 {
                     Hashtable hash = wc.GetWeeksHash();
                     String _yr = dRow["dt2"] != DBNull.Value ? dRow["dt2"].ToString() : "";
                     String _mnth = dRow["dt1"] != DBNull.Value ? dRow["dt1"].ToString() : "";
                     foreach (string key in hash.Keys)
                     {
                         wc.PopulateSchedule(Convert.ToInt32(ViewState["twc_project_number"].ToString()), _yr, _mnth + "(" + _yr + ")", hash[key].ToString(), iCnt, "0");
                     }
                     iCnt++;
                 }
             }
             catch (Exception ex)
             {
                 Response.Write(ex.Message);
             }
             DisplaySchedulingGrid();
         }
         else
         {
             Response.Write("No Data");
         }
     }
     else
     {
         Response.Write("Construction Start date and Construction End date should be Set");
     }
 }
开发者ID:frdharish,项目名称:WhitfieldAPPs,代码行数:45,代码来源:Whitfield_projectInfo.aspx.cs


注:本文中的Whitfieldcore.GetSchedule方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。