Probleme usercontrol, insertion
Bonjour,
j'a créé un webcontrol,
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
|
<ajaxToolkit:ModalPopupExtender ID="ModalPopupExtender1" runat="server"
PopupControlID="PNL" OkControlID="ButtonOk" CancelControlID="ButtonCancel" BackgroundCssClass="modalBackground"
PopupDragHandleControlID="header" TargetControlID="[TargetControlID]" />
<asp:Panel ID="PNL" runat="server" CssClass="confirm-dialog" style="display:none;">
<div class="container">
<asp:Panel ID="header" runat="server">
<div class="header">
<asp:Label ID="Title"
runat="server" CssClass="msg" Text="[Title]" />
<asp:LinkButton ID="ButtonClose"
runat="server" CssClass="close"
OnClientClick="cancelClick(); return false;" />
</div>
</asp:Panel>
<div class="body">
<!----------Debut partie 2 ---------------------------------------->
<asp:Label ID="Question"
runat="server" CssClass="msg" Text="[Question]" />
<!----------Fin partie 2 -------------------------->
</div>
<div class="footer">
toto
</div>
</div>
</asp:Panel> |
Dans ce webcontrol, on peut distinguer 2 parties , une propre à mon webcontrol et une autre que j'aimerais generalisé à d'autres webcontrol (boite modale).
Le probleme est que ma partie 2 est au milieu de ma partie 1.
Comment peut on mutualiser la partie 1. J'aimerais en faire un webcontrol que j'associerais avec la partie 1. Est ce possible et comment ?
Mon idée serait de faire cela :
Code:
1 2 3 4 5
|
<monwebcontrolpartie1>
<asp:Label ID="Question"
runat="server" CssClass="msg" Text="[Question]" />
</monwebcontrolpartie1> |
ou
Code:
1 2 3 4 5 6
|
<monwebcontrolpartie1 idcontrolpanel="toto"/>
<asp:panel id="toto">
<asp:Label ID="Question"
runat="server" CssClass="msg" Text="[Question]" />
</asp:panel> |
JE cherche des exemples mais je n'en vois pas, quelqu'un pourrais me donner des pistes ???