SNF開發平臺WinForm之十五-時間軸控件使用-SNF快速開發平臺3.3-Spring.Net.Framework

1、顯示效果以下:html

2、在控件庫裏選擇UCTimeAxis 拖拽到窗體裏。spring

3、加入如下代碼,在load事件裏進行調用就能夠運行了。服務器

        #region 給時間軸控件加載數據
        private void UCTimeAxisData() 
        {
            //增長節點
            List<KeyValuePair<string, string>> list = new List<KeyValuePair<string, string>>();
            list.Add(new KeyValuePair<string, string>("1", "讀取配置"));
            list.Add(new KeyValuePair<string, string>("2", "選擇模板"));
            list.Add(new KeyValuePair<string, string>("3", "確認數據"));
            list.Add(new KeyValuePair<string, string>("4", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("5", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("6", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("7", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("8", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("9", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("10", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("11", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("12", "生成代碼"));

            list.Add(new KeyValuePair<string, string>("11", "讀取配置"));
            list.Add(new KeyValuePair<string, string>("12", "選擇模板"));
            list.Add(new KeyValuePair<string, string>("13", "確認數據"));
            list.Add(new KeyValuePair<string, string>("14", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("15", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("16", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("17", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("18", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("19", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("110", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("111", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("112", "生成代碼"));

            list.Add(new KeyValuePair<string, string>("111", "讀取配置"));
            list.Add(new KeyValuePair<string, string>("112", "選擇模板"));
            list.Add(new KeyValuePair<string, string>("113", "確認數據"));
            list.Add(new KeyValuePair<string, string>("114", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("115", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("116", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("117", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("118", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("119", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("1110", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("1111", "生成代碼"));
            list.Add(new KeyValuePair<string, string>("1112", "生成代碼"));

            UCTimeAxis ucTimeAxis = new UCTimeAxis(list, 0);//0爲橫向顯示,1縱向顯示
            //設置,已經完成狀態值
            ucTimeAxis.SetStepValues.Add("1");
            ucTimeAxis.SetStepValues.Add("2");
            ucTimeAxis.SetStepValues.Add("3");

            ////是否須要點擊 label標籤事件,若是須要用下面代碼進行綁定
            //ucTimeAxis.lc2 = new UCTimeAxis.TimeAxisClick2(AxisItemClick);

            scrollTimeAxis.Controls.Clear();
            scrollTimeAxis.Controls.Add(ucTimeAxis);
            //處理是否出現滾動條
            this.scrollTimeAxis.AutoScrollMinSize = new Size(list.Count * 80, 10);
            //填充整個控件
            ucTimeAxis.Dock = DockStyle.Fill;
        }

        //是否須要點擊 label標籤事件,若是須要用下面代碼進行綁定
        public void AxisItemClick(string labelName, string labelText)
        {
            MessageBox.Show(labelName + labelText);
        }

        #endregion

 4、關鍵點在於;mvc

   0爲橫向顯示,1縱向顯示框架

    點擊標籤是否有事件處理:ucTimeAxis.lc2 = new UCTimeAxis.TimeAxisClick2(AxisItemClick);asp.net

 

這個系列教程文檔,歡迎轉載: this

SNF開發平臺WinForm之五-高級查詢使用說明-http://www.cnblogs.com/spring_wang/p/6116640.html

SNF開發平臺WinForm之四-開發-主細表管理頁面-http://www.cnblogs.com/spring_wang/p/6116626.html

SNF開發平臺WinForm之三-開發-單表選擇控件建立-http://www.cnblogs.com/spring_wang/p/6116592.html

SNF開發平臺WinForm之二-開發-單表表單管理頁面-http://www.cnblogs.com/spring_wang/p/6116572.html

SNF開發平臺WinForm之一-開發-單表表格編輯管理頁面-http://www.cnblogs.com/spring_wang/p/6116523.html

Winform開發框架之圖表報表在線設計器2-圖表-SNF.EasyQuery項目--SNF快速開發平臺3.3-Spring.Net.Framework

Winform開發框架之圖表報表在線設計器-報表-SNF.EasyQuery項目--SNF快速開發平臺3.3-Spring.Net.Framework

Winform開發框架之通用附件管理模塊 --SNF快速開發平臺3.3-Spring.Net.Framework

SNFAutoupdater通用自動升級組件V2.0-WinForm

SNF快速開發平臺3.2之--.Net可擴展的單據編號生成器-SNF.CodeRule

SNF快速開發平臺3.1之--審覈流(3)低調奢華,簡單不凡,實例演示-SNF.WorkFlow

SNF快速開發平臺3.1之--審覈流(2)流程設計-SNF.WorkFlow功能使用說明

SNF快速開發平臺3.1之--審覈流(1)SNF.WorkFlow審覈流簡介

SNF快速開發平臺3.0之--完美的代碼生成器SNF.CodeGenerator-快速開發者的利器

基於MVC4+EasyUI的Web開發框架--Spring.Net.FrameworkV3.0整體介紹

SNF快速開發平臺3.0之--MVC 打印解決方案

SNF快速開發平臺3.0之--文件批量上傳-統一附件管理器-在線預覽文件(有互聯網和沒有兩種)

SNF快速開發平臺3.0之--asp.net mvc4 強大的導出和不須要上傳文件的批量導入EXCEL

SNF快速開發平臺3.0之MVC通用控件庫展現-Asp.net+MVC4.0+WebAPI+EasyUI+Knockout

SNF快速開發平臺3.0之BS頁面展現和九大優勢-部分頁面顯示效果-Asp.net+MVC4.0+WebAPI+EasyUI +Knockout

SNF快速開發平臺3.0之-界面個性化配置+10種皮膚+7種菜單-Asp.net+MVC4.0+WebAPI+EasyUI+Knockout

SNF快速開發平臺3.0之-CS頁面-Asp.net+Spring.Net.Framework

SNF快速開發平臺3.0之--系統裏廣播的做用--迅速及時、簡明扼要的把信息發送給接收者

相關文章
相關標籤/搜索