FdoToolbox.Base.Controls.FdoConnectCtl.AddProperty C# (CSharp) Method

AddProperty() public method

Adds the property.
public AddProperty ( FdoToolbox p ) : void
p FdoToolbox The p.
return void
        public void AddProperty(FdoToolbox.Core.Connections.DictionaryProperty p)
        {
            DataGridViewRow row = new DataGridViewRow();
            DataGridViewTextBoxCell nameCell = new DataGridViewTextBoxCell();
            nameCell.Value = p.LocalizedName;

            DataGridViewTextBoxCell valueCell = new DataGridViewTextBoxCell();
            if (p.IsFile || p.IsPath)
            {
                valueCell.ContextMenuStrip = ctxHelper;
                valueCell.ToolTipText = "Right click for helpful options";
            }
            valueCell.Value = p.DefaultValue;

            row.Cells.Add(nameCell);
            row.Cells.Add(valueCell);

            grdProperties.Rows.Add(row);

            if (p.Protected)
                pwdCells.Add(valueCell);
        }