0

Hii,

I m working in Asp.net 2.0 with C#.... I have a custom control and i have to use 'Datasource' property which is exactly like a repeater having. Any idea regarding this pls help me.

1 Answer 1

1

Any public property with a setter will be exposed in the markup:

public class MyControl : UserControl
{
   public object DataSource {get; set;}
}

This will allow you to set the DataSource property either through the HTML or in code.

Is that what you meant?

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.