Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Building Controls > VS.NET designer support for nested custom web form controls

Reply
Thread Tools

VS.NET designer support for nested custom web form controls

 
 
Casper
Guest
Posts: n/a
 
      06-08-2004
I have a custom web form control, that can contain other custom
controls.
Is it possible to add designer support for this, so I can drag a
custom control onto another control?
 
Reply With Quote
 
 
 
 
John Saunders
Guest
Posts: n/a
 
      06-08-2004
"Casper" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed) om...
> I have a custom web form control, that can contain other custom
> controls.
> Is it possible to add designer support for this, so I can drag a
> custom control onto another control?


Yes and no.

Your outer control could derive from Panel, for instance, in which case you
could drag other controls onto it in the same way as a Panel control works.

But it would be _exactly_ like a Panel control. If I remember correctly,
there is a trade-off between this "drag" behavior and the ability to have
your outer control do its own design-time rendering. I believe that the
designer will ignore your outer control designer's GetDesignTimeHtml method
and simply render the inner controls.

Alternatively, your outer control could support templates. You couldn't
directly drag controls onto it then, but you could enter template editing
mode and then drag controls into the template editing area.
--
John Saunders
johnwsaundersiii at hotmail


 
Reply With Quote
 
 
 
 
Casper
Guest
Posts: n/a
 
      06-09-2004
"John Saunders" <(E-Mail Removed)> wrote in message news:<#(E-Mail Removed)>...
> "Casper" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed) om...
> > I have a custom web form control, that can contain other custom
> > controls.
> > Is it possible to add designer support for this, so I can drag a
> > custom control onto another control?

>
> Yes and no.
>
> Your outer control could derive from Panel, for instance, in which case you
> could drag other controls onto it in the same way as a Panel control works.
>
> But it would be _exactly_ like a Panel control. If I remember correctly,
> there is a trade-off between this "drag" behavior and the ability to have
> your outer control do its own design-time rendering. I believe that the
> designer will ignore your outer control designer's GetDesignTimeHtml method
> and simply render the inner controls.
>

That solution would be good enought for me, I'll work a little bit
more with that idea.

> Alternatively, your outer control could support templates. You couldn't
> directly drag controls onto it then, but you could enter template editing
> mode and then drag controls into the template editing area.

That could also be a good solution. Do you have some examples or
guides, something to get me started with templates.

Thanks for you reply
 
Reply With Quote
 
John Saunders
Guest
Posts: n/a
 
      06-09-2004
"Casper" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed) om...
> "John Saunders" <(E-Mail Removed)> wrote in message

news:<#(E-Mail Removed)>...
> > "Casper" <(E-Mail Removed)> wrote in message
> > news:(E-Mail Removed) om...
> > > I have a custom web form control, that can contain other custom
> > > controls.
> > > Is it possible to add designer support for this, so I can drag a
> > > custom control onto another control?

....
> > Alternatively, your outer control could support templates. You couldn't
> > directly drag controls onto it then, but you could enter template

editing
> > mode and then drag controls into the template editing area.

> That could also be a good solution. Do you have some examples or
> guides, something to get me started with templates.


Actually, no, I don't have an example handy. If I were you, I'd start with
the MSDN documentation.
--
John Saunders
johnwsaundersiii at hotmail


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Sharepoint Designer/ Expression Web Designer : adding item in toolbox ? Steve B. ASP .Net 4 06-01-2007 04:29 AM
Web Form designer and HTML controls Edward Diener ASP .Net 0 07-20-2006 03:17 PM
Giving Web User Controls designer support SimonH ASP .Net 2 02-01-2005 03:26 PM
Giving Web User Controls designer support SimonH ASP .Net Web Controls 2 02-01-2005 03:26 PM
Designer Support for Selecting Web Form control Paul Ingles ASP .Net Building Controls 4 07-19-2003 04:53 PM



Advertisments