Sharepoint自定义字段和SPFieldMultiColumnValue

时间:2013-08-14 05:08:14

标签: sharepoint-2010

我正在尝试在SharePoint中学习自定义字段。任何人都可以帮助我学习下面指定的SPFieldMultiColumnValue。

    public override object Value
    {
        get
        {
            this.EnsureChildControls();

            SPFieldMultiColumnValue mcv = new SPFieldMultiColumnValue(2);
            mcv[0] = txtDurationId.Text;
            mcv[1] = DDLDurationID.SelectedValue;

            return mcv;
        }
        set
        {
            this.EnsureChildControls();

            SPFieldMultiColumnValue mcv = (SPFieldMultiColumnValue)this.ItemFieldValue;
            txtDurationId.Text = mcv[0];
            DDLDurationID.SelectedValue = mcv[1];
        }
    }

0 个答案:

没有答案