public ActReadTextFileEditPage(ActReadTextFile act)
        {
            InitializeComponent();
            mAct = act;
            TextFileNameTextBox.Init(Context.GetAsContext(mAct.Context), mAct.GetOrCreateInputParam(ActReadTextFile.Fields.TextFilePath));
            TextToWrite.Init(Context.GetAsContext(mAct.Context), mAct.GetOrCreateInputParam(ActReadTextFile.Fields.TextToWrite));
            LineNumber.Init(Context.GetAsContext(mAct.Context), mAct.GetOrCreateInputParam(ActReadTextFile.Fields.AppendLineNumber));

            mAct.SolutionFolder = WorkSpace.Instance.Solution.Folder.ToUpper();

            GingerCore.General.FillComboFromEnumObj(FileActionMode, mAct.FileActionMode);
            GingerCore.GeneralLib.BindingHandler.ObjFieldBinding(FileActionMode, ComboBox.SelectedValueProperty, mAct, "FileActionMode");

            GingerCore.General.FillComboFromEnumObj(TextFileEncoding, mAct.TextFileEncoding);
            GingerCore.GeneralLib.BindingHandler.ObjFieldBinding(TextFileEncoding, ComboBox.SelectedValueProperty, mAct, "TextFileEncoding");

            GingerCore.General.FillComboFromEnumObj(TextFileAppendType, mAct.AppendAt);
            GingerCore.GeneralLib.BindingHandler.ObjFieldBinding(TextFileAppendType, ComboBox.SelectedValueProperty, mAct, "AppendAt");
        }
Exemple #2
0
        public ActReadTextFileEditPage(ActReadTextFile act)
        {
            InitializeComponent();
            mAct = act;
            TextFileNameTextBox.Init(mAct.GetOrCreateInputParam(ActReadTextFile.Fields.TextFilePath));
            TextToWrite.Init(mAct.GetOrCreateInputParam(ActReadTextFile.Fields.TextToWrite));
            LineNumber.Init(mAct.GetOrCreateInputParam(ActReadTextFile.Fields.AppendLineNumber));

            mAct.SolutionFolder = WorkSpace.UserProfile.Solution.Folder.ToUpper();

            App.FillComboFromEnumVal(FileActionMode, mAct.FileActionMode);
            App.ObjFieldBinding(FileActionMode, ComboBox.SelectedValueProperty, mAct, "FileActionMode");

            App.FillComboFromEnumVal(TextFileEncoding, mAct.TextFileEncoding);
            App.ObjFieldBinding(TextFileEncoding, ComboBox.SelectedValueProperty, mAct, "TextFileEncoding");

            App.FillComboFromEnumVal(TextFileAppendType, mAct.AppendAt);
            App.ObjFieldBinding(TextFileAppendType, ComboBox.SelectedValueProperty, mAct, "AppendAt");
        }