예제 #1
0
        public void Reload()
        {
            Logs.Children.Clear();
            ProjectControlSource source = PersistableJson.Load <ProjectControlSource>();

            foreach (ProjectControlItem item in source.Logs)
            {
                RadioButton but = new RadioButton();
                but.Content   = item.LogPath;
                but.GroupName = "group";
                Logs.Children.Add(but);
            }
        }
예제 #2
0
        public static void Init()
        {
            ProjectControlSource source = new ProjectControlSource();

            source.Logs = new List <ProjectControlItem>();
            ProjectControlItem item1 = new ProjectControlItem()
            {
                LogPath = "Algo Windows Service"
            };
            ProjectControlItem item2 = new ProjectControlItem()
            {
                LogPath = "LCP Trading Monitor"
            };
            ProjectControlItem item3 = new ProjectControlItem()
            {
                LogPath = "LCP TT Gateway"
            };
            ProjectControlItem item4 = new ProjectControlItem()
            {
                LogPath = "Matlab Server Windows Service"
            };
            ProjectControlItem item5 = new ProjectControlItem()
            {
                LogPath = "Optimizer Windows Service"
            };
            ProjectControlItem item6 = new ProjectControlItem()
            {
                LogPath = "Task Scheduler WS"
            };

            source.Logs.Add(item1);
            source.Logs.Add(item2);
            source.Logs.Add(item3);
            source.Logs.Add(item4);
            source.Logs.Add(item5);
            source.Logs.Add(item6);
            source.LogPath = @"c:\LCP\Logs\";
            source.Save();
        }