KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I've got the following Generic usercontrol declared: public partial class MessageBase<T> : UserControl { protected T myEntry; public MessageBase() { InitializeComponent(); } public MessageBase(T newEntry) { InitializeComponent(); myEntry = newEntry; } } } But the compiler won't allow me to do this: public partial class MessageControl : MessageBase<Post> { public MessageControl() { InitializeComponent(); } } How do I create a generic user control in C#?
Tags (comma-separated)
Save Edits
Cancel