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


C# Editor.PutInt32方法代码示例

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


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

示例1: WritePortSetup

 private void WritePortSetup(Editor editor)
 {
     if (_hasPorts)
     {
         //保存选中的端口
         editor.PutInt32("selectedPort", comboBox_port.SelectedIndex);
         //保存设置的波特率
         editor.PutInt32("baudRate", comboBox_baudrate.SelectedIndex);
         //保存设置的校验方式
         editor.PutInt32("parity", comboBox_parity.SelectedIndex);
         //保存设置的数据位
         editor.PutInt32("dataBits", comboBox_databit.SelectedIndex);
         //保存设置的停止位
         editor.PutInt32("stopBits", comboBox_stopbit.SelectedIndex);
         //保存自动发送数据时间间隔
         editor.PutInt32("intervalTime", Convert.ToInt32(textBox_sendPeriod.Text));
         //保存接收方式
         editor.PutBoolean("acceptChar", checkBox_receiveHex.Checked);
         //保存标志变量,即是否在接收框中显示信息。
         editor.PutBoolean("showInfo", showInfo);
     }
 }
开发者ID:potterhere,项目名称:FreescalePlatform,代码行数:22,代码来源:Configuration.cs

示例2: WriteOthers

 private void WriteOthers(Editor editor)
 {
     editor.PutInt32("comboboxCCDPath", comboBoxCCDPath.SelectedIndex);
 }
开发者ID:potterhere,项目名称:FreescalePlatform,代码行数:4,代码来源:Configuration.cs

示例3: ResetRealTimeSetup

        private void ResetRealTimeSetup(Editor editor)
        {
            int realtimeNumber = 1;
            editor.PutInt32("RealtimeNum", realtimeNumber);

            for (var i = 0; i < realtimeNumber; i++)
            {
                var txtName = string.Format("textElectName{0}", i + 1);
                editor.PutString(txtName, "Name");

                var txtValue = string.Format("txtElectValue{0}", i + 1);
                editor.PutString(txtValue, "0");
            }
        }
开发者ID:potterhere,项目名称:FreescalePlatform,代码行数:14,代码来源:Configuration.cs

示例4: WriteDiySetup

        private void WriteDiySetup(Editor editor)
        {
            //保存自定义参数的数量
            editor.PutInt32("DIY_Number", Convert.ToInt32(textBox_DIY_Number.Text));

            //保存自定义参数的其他信息
            var total = Convert.ToInt32(textBox_DIY_Number.Text);
            for (var i = 0; i < total; i++)
            {
                var controlCheckState = panel_add_DIYControls.Controls.Find("checkBox_Def" + Convert.ToString(i + 1), true);
                if (controlCheckState.Length > 0)
                {
                    var checkboxSelect = (CheckBox)controlCheckState[0];

                    var checkState = string.Format("DIY_CheckState{0}", i + 1);
                    editor.PutBoolean(checkState, checkboxSelect.Checked);
                }

                var controlName = panel_add_DIYControls.Controls.Find("txtName" + Convert.ToString(i + 1), true);
                if (controlName.Length > 0)
                {
                    var txtBox = (TextBox)controlName[0];

                    var txtName = string.Format("DIY_TextName{0}", i + 1);
                    editor.PutString(txtName, txtBox.Text);
                }

                var controlValue = panel_add_DIYControls.Controls.Find("txtValue" + Convert.ToString(i + 1), true);
                if (controlValue.Length > 0)
                {
                    var txtBox = (TextBox)controlValue[0];

                    var txtValue = string.Format("DIY_TextValue{0}", i + 1);
                    editor.PutString(txtValue, txtBox.Text);
                }

                var controlButton = panel_add_DIYControls.Controls.Find("buttonSubmit" + Convert.ToString(i + 1), true);
                if (controlButton.Length > 0)
                {
                    var button = (Button)controlButton[0];

                    var buttonName = string.Format("buttonSubmit{0}", i + 1);
                    editor.PutString(buttonName, "修改");
                }
            }
        }
开发者ID:potterhere,项目名称:FreescalePlatform,代码行数:46,代码来源:Configuration.cs

示例5: ResetCustomSetup

        private void ResetCustomSetup(Editor editor)
        {
            int diyNumber = 1;
            editor.PutInt32("DIY_Number", diyNumber);

            for (var i = 0; i < diyNumber; i++)
            {
                var checkState = string.Format("DIY_CheckState{0}", i + 1);
                editor.PutBoolean(checkState, false);

                var txtNameDIY = string.Format("DIY_TextName{0}", i + 1);
                editor.PutString(txtNameDIY, "Names");

                var txtValueDIY = string.Format("DIY_TextValue{0}", i + 1);
                editor.PutString(txtValueDIY, "1.0");

                var buttonDIY = string.Format("buttonSubmit{0}", i + 1);
                editor.PutString(buttonDIY, @"修改");
            }
        }
开发者ID:potterhere,项目名称:FreescalePlatform,代码行数:20,代码来源:Configuration.cs


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