want to have <cc:UserControl>some text and tags</cc:UserControl>... How?

Discussion in 'ASP .Net' started by ThunderMusic, Dec 20, 2005.

  1. ThunderMusic

    ThunderMusic Guest

    Hi
    I want to do just like in the subject ... to have some text and tags
    between the start and end tags of my user-control.

    Is there a simple way of doing that? for instance, between the tags, there
    would be a table with <table>, <tr> and <td> and all the stuff I could need.
    but everytime I try puting something between the tags, I get an error.

    My control is all done, only this functionality is missing. Can someone help
    me please?

    Thanks

    ThunderMusic
    ThunderMusic, Dec 20, 2005
    #1
    1. Advertising

  2. ThunderMusic

    Damien Guest

    Re: want to have <cc:UserControl>some text and tags</cc:UserControl>... How?

    ThunderMusic wrote:
    > Hi
    > I want to do just like in the subject ... to have some text and tags
    > between the start and end tags of my user-control.
    >
    > Is there a simple way of doing that? for instance, between the tags, there
    > would be a table with <table>, <tr> and <td> and all the stuff I could need.
    > but everytime I try puting something between the tags, I get an error.
    >
    > My control is all done, only this functionality is missing. Can someone help
    > me please?
    >
    > Thanks
    >
    > ThunderMusic


    Hi,

    have you looked at the ParseChildrenAttribute? Under VS 2003, the help
    topic is

    ms-help://MS.VSCC.2003/MS.MSDNQTR.2003FEB.1033/cpguide/html/cpconusingparsechildrenattribute.htm

    (Which you may have to reassemble into one line).

    Damien
    Damien, Dec 20, 2005
    #2
    1. Advertising

  3. ThunderMusic

    ThunderMusic Guest

    Re: want to have <cc:UserControl>some text and tags</cc:UserControl>... How?

    ok, if I understand it well, if I put something like [ParseChildren(false)]
    before my class, I should be able to put almost anything between my control
    tags? I'm asking the question because I don't have access to my control
    right now, but I want to know if I understood it well. will it work for a
    usercontrol?

    Thanks a lot

    ThunderMusic

    "Damien" <> wrote in message
    news:...
    > ThunderMusic wrote:
    >> Hi
    >> I want to do just like in the subject ... to have some text and tags
    >> between the start and end tags of my user-control.
    >>
    >> Is there a simple way of doing that? for instance, between the tags,
    >> there
    >> would be a table with <table>, <tr> and <td> and all the stuff I could
    >> need.
    >> but everytime I try puting something between the tags, I get an error.
    >>
    >> My control is all done, only this functionality is missing. Can someone
    >> help
    >> me please?
    >>
    >> Thanks
    >>
    >> ThunderMusic

    >
    > Hi,
    >
    > have you looked at the ParseChildrenAttribute? Under VS 2003, the help
    > topic is
    >
    > ms-help://MS.VSCC.2003/MS.MSDNQTR.2003FEB.1033/cpguide/html/cpconusingparsechildrenattribute.htm
    >
    > (Which you may have to reassemble into one line).
    >
    > Damien
    >
    ThunderMusic, Dec 20, 2005
    #3
  4. ThunderMusic

    Damien Guest

    Re: want to have <cc:UserControl>some text and tags</cc:UserControl>... How?

    ThunderMusic wrote:
    > ok, if I understand it well, if I put something like [ParseChildren(false)]
    > before my class, I should be able to put almost anything between my control
    > tags? I'm asking the question because I don't have access to my control
    > right now, but I want to know if I understood it well. will it work for a
    > usercontrol?
    >
    > Thanks a lot
    >
    > ThunderMusic
    >

    Hi,

    Your original question seemed to concern a custom control, rather than
    a user control (just guessing, since you had the cc: prefix). It works
    for custom controls. E.g. from VB:

    <ParseChildren(False)> _
    Public Class Blarg
    Inherits System.Web.UI.WebControls.WebControl

    'Implement Custom Control Here
    End Class

    But I'm not sure how it would work with a user control. I've never
    thought or tried to apply attributes to these. I'd have expected it to
    be a directive of some kind, but I cannot see anything. Anyone else
    know if it's possible to apply attributes to user controls?

    Damien
    Damien, Dec 21, 2005
    #4
  5. ThunderMusic

    ThunderMusic Guest

    Re: want to have <cc:UserControl>some text and tags</cc:UserControl>... How?

    anyway I've done it with a custom control instead of a user control, it
    seemed easier that way.

    thanks a lot

    "Damien" <> a écrit dans le message de
    news: ...
    > ThunderMusic wrote:
    >> ok, if I understand it well, if I put something like
    >> [ParseChildren(false)]
    >> before my class, I should be able to put almost anything between my
    >> control
    >> tags? I'm asking the question because I don't have access to my control
    >> right now, but I want to know if I understood it well. will it work for a
    >> usercontrol?
    >>
    >> Thanks a lot
    >>
    >> ThunderMusic
    >>

    > Hi,
    >
    > Your original question seemed to concern a custom control, rather than
    > a user control (just guessing, since you had the cc: prefix). It works
    > for custom controls. E.g. from VB:
    >
    > <ParseChildren(False)> _
    > Public Class Blarg
    > Inherits System.Web.UI.WebControls.WebControl
    >
    > 'Implement Custom Control Here
    > End Class
    >
    > But I'm not sure how it would work with a user control. I've never
    > thought or tried to apply attributes to these. I'd have expected it to
    > be a directive of some kind, but I cannot see anything. Anyone else
    > know if it's possible to apply attributes to user controls?
    >
    > Damien
    >
    ThunderMusic, Dec 21, 2005
    #5
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Jim Cobban
    Replies:
    9
    Views:
    403
    Roedy Green
    Apr 18, 2004
  2. Kwasi
    Replies:
    13
    Views:
    592
    Kwasi Yeboah via JavaKB.com
    Dec 1, 2004
  3. UJ
    Replies:
    1
    Views:
    290
  4. dolphin
    Replies:
    3
    Views:
    359
    rossum
    Mar 9, 2007
  5. POLO TSHIRT
    Replies:
    0
    Views:
    193
    POLO TSHIRT
    Nov 8, 2010
Loading...

Share This Page