Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   ASP .Net Web Controls (http://www.velocityreviews.com/forums/f63-asp-net-web-controls.html)
-   -   Web Custom Control Designer (http://www.velocityreviews.com/forums/t773283-web-custom-control-designer.html)

VR 05-15-2004 11:21 PM

Web Custom Control Designer
 
Hi, I'm developing a Web Custom Control and following the MSDN walkthroughs
I got a little confused about one thing using the designer class:

In the sample it shows how to render some label text using <h1> to make it
bigger but when I run the sample the <h1> is left in the designer, it do not
get to my web page (ok, that should be the behavior)

My question is: do I need to put inside the designer class just the output I
want to use in Design mode and all I want to use both in design and run-time
modes in the Render method? Or is there a way to propagate the designer
behavior to the web page? (like accessing the designer properties and output
in the render method?)


thanks in advance,
Victor




Robert Koritnik 05-19-2004 05:40 PM

Re: Web Custom Control Designer
 
My answer is:
Normally when creating your own custom control designer you make somehow
different rendering methods. Probably you don't have the correct look and
feel of the control in design time so there is actually no need to create a
"fully blown" runtime rendering at designtime.
Normally you just display the control and make any template editors and so
on and if it's databound custom control you bind to some dummy data or just
a few records from the design time binded datasource.

Anyway. Why make the same rendering at design time?

the control itself could maybe get the information of it's designer class
(never done that, but if the VSE can, why the control couldn't), but it's
probably better to make rendering in the control itself and get it via
designer.component property.

Robert.

"VR" <vcreb@hotmail.com> wrote in message
news:e$jEGStOEHA.1348@TK2MSFTNGP12.phx.gbl...
> Hi, I'm developing a Web Custom Control and following the MSDN

walkthroughs
> I got a little confused about one thing using the designer class:
>
> In the sample it shows how to render some label text using <h1> to make it
> bigger but when I run the sample the <h1> is left in the designer, it do

not
> get to my web page (ok, that should be the behavior)
>
> My question is: do I need to put inside the designer class just the output

I
> want to use in Design mode and all I want to use both in design and

run-time
> modes in the Render method? Or is there a way to propagate the designer
> behavior to the web page? (like accessing the designer properties and

output
> in the render method?)
>
>
> thanks in advance,
> Victor
>
>
>




VR 05-21-2004 03:44 AM

Re: Web Custom Control Designer
 
ok, thanks a lot, you gave the answers I was looking for

regards,
Victor Reboucas


"Robert Koritnik" <robert.koritnik.removethis@avtenta.si> wrote in message
news:u3JVShcPEHA.3804@TK2MSFTNGP12.phx.gbl...
> My answer is:
> Normally when creating your own custom control designer you make somehow
> different rendering methods. Probably you don't have the correct look and
> feel of the control in design time so there is actually no need to create

a
> "fully blown" runtime rendering at designtime.
> Normally you just display the control and make any template editors and so
> on and if it's databound custom control you bind to some dummy data or

just
> a few records from the design time binded datasource.
>
> Anyway. Why make the same rendering at design time?
>
> the control itself could maybe get the information of it's designer class
> (never done that, but if the VSE can, why the control couldn't), but it's
> probably better to make rendering in the control itself and get it via
> designer.component property.
>
> Robert.
>
> "VR" <vcreb@hotmail.com> wrote in message
> news:e$jEGStOEHA.1348@TK2MSFTNGP12.phx.gbl...
> > Hi, I'm developing a Web Custom Control and following the MSDN

> walkthroughs
> > I got a little confused about one thing using the designer class:
> >
> > In the sample it shows how to render some label text using <h1> to make

it
> > bigger but when I run the sample the <h1> is left in the designer, it do

> not
> > get to my web page (ok, that should be the behavior)
> >
> > My question is: do I need to put inside the designer class just the

output
> I
> > want to use in Design mode and all I want to use both in design and

> run-time
> > modes in the Render method? Or is there a way to propagate the designer
> > behavior to the web page? (like accessing the designer properties and

> output
> > in the render method?)
> >
> >
> > thanks in advance,
> > Victor
> >
> >
> >

>
>





All times are GMT. The time now is 11:00 AM.

Powered by vBulletin®. Copyright ©2000 - 2013, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.


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 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57