Solved

How to define a property in the user control?

Posted on 2006-06-20
3
607 Views
Last Modified: 2006-11-18
I have created a user control: myUserControl.ascx. A property is defined as follows:

private string target;

    public String Target
    {
        get { return target; }
        set { target = value;}
    }

myUserControl is registered with the master page:
<%@ Register Src="../UserControls/myUserControl.ascx" TagName="myUserControl" TagPrefix="uc11" %>

My intention is to set the property Target externally. But when I click on the user control on the master page, it shows nothing on the property page. Anyone can offer some ideas?
0
Comment
Question by:chuang4630
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 7

Accepted Solution

by:
kGenius earned 500 total points
ID: 16942253
0
 
LVL 1

Author Comment

by:chuang4630
ID: 16943837
This link provides useful informaton for exposing the property in the designer.

Actually, developer can set the property in the aspx while declaring the user control as follows:

<uc11:myUserControl ID="myUserControl1" runat="server" Target="myTestTarget.aspx" />


0
 
LVL 7

Expert Comment

by:kGenius
ID: 16944514
as you say. :-)

kGenius
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

One of the pain points with developing AJAX, JavaScript, JQuery, and other client-side behaviors is that JavaScript doesn’t allow for cross domain request for pulling content. For example, JavaScript code on www.johnchapman.name could not pull conte…
Introduction This article shows how to use the open source plupload control to upload multiple images. The images are resized on the client side before uploading and the upload is done in chunks. Background I had to provide a way for user…
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…

634 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question