开发者

Properties from partial class are not accessible from designer in DataGridView

I have generated classes of Linq to database and i want to display this tables in DataGridView. One table is connected to another 开发者_Go百科and i want to display also some columns from this table. I created partial class where i defined properties:

public partial class Table
{
    public long other_table_id
    {
        get { return this.other_table.id; }
        set { }
    }
}

But i cant see them in visual studio 2010 Premium designer when i try to add new column:/ If i copy this code to generated class, then it works and i can see this properties in designer...

i tried all these atributes:

[System.ComponentModel.Browsable(true)]
[System.ComponentModel.EditorBrowsable(EditorBrowsableState.Always)]
[System.ComponentModel.Bindable(true)]

Thanks a lot!


Try browsable attribute on the property. Implement setter property to set in property grid

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜