CodeVerge.Net Beta


   Explore    Item Entry   Register  Login  
Microsoft News
Asp.Net Forums
IBM Software
Borland Forums
Adobe Forums
Novell Forums

ASP.NET Web Hosting – 3 Months Free!



Zone: > NEWSGROUP > Asp.Net Forum > windows_hosting.hosting_open_forum Tags:
Item Type: NewsGroup Date Entered: 2/20/2003 1:25:28 PM Date Modified: Subscribers: 0 Subscribe Alert
Rate It:
(NR, 0)
XPoints: N/A Replies: 4 Views: 16 Favorited: 0 Favorite
Can Reply:  No Members Can Edit: No Online: Yes
5 Items, 1 Pages 1 |< << Go >> >|
kurt_rds
Asp.Net User
Styles in composite controls2/20/2003 1:25:28 PM

0/0

Good morning. I've been having an issue trying to get design time support for some styles i created for a composite control. I have a control that contains a textbox so i wrote a public TextBoxStyle property that will ultimately control the style of the textbox. I followed the stepthrough of the book ASP.NET Server Controls in chapter 13. However, when i load my project and access the TextBoxStyle property in my properties explorer I'm not getting access to all the style properties. In fact I see the property listing int he window but I can't do anything with it. Am i missing something here? Thanks!


'///////////////////////////////////////////////////////////

<VB.NET CODE>

Public mTextboxStyle As Style

<Browsable(True),
Category("Style"),
Description("The style to be applied to the textbox.")> _
Public ReadOnly Property TextBoxStyle() As Style
Get
If IsNothing(mTextboxStyle) Then
If isTrackingViewState Then
CType(mTextboxStyle, IStateManager).TrackViewState()
End If
End If
Return mTextboxStyle
End Get
End Property
joteke
Asp.Net User
Re: Styles in composite controls2/20/2003 1:42:38 PM

0/0

Try doing it this way (code is in C#, but I believe you get the point)


private Style textBoxStyle;

[
Category("Style"),
DesignerSerializationVisibility(DesignerSerializationVisibility.Content),
NotifyParentProperty(true),
PersistenceMode(PersistenceMode.InnerProperty)
]
public virtual Style TextBoxStyle
{
get
{
if(textBoxStyle==null)
{
textBoxStyle=new Style();

if(IsTrackingViewState)
((IStateManager)textBoxStyle).TrackViewState();
}
return textBoxStyle;
}
}

Thanks,

Teemu Keiski
Finland, EU
kurt_rds
Asp.Net User
Re: Styles in composite controls2/20/2003 1:55:30 PM

0/0

Thanks, That worked -- i figured i was overlooking something!!!!
joteke
Asp.Net User
Re: Styles in composite controls2/20/2003 2:03:30 PM

0/0

Shortly, you need to provide those attributes I demonstrated and also if member variable reference is null (Nothing), create new instance and if ViewState is being tracked, set the Style to also track it's state. After that return the reference.

Meaning of attributes:
DesignerSerializationVisibility(DesignerSerializationVisibility.Content)
-serialize objects subproperties rather than object itself

NotifyParentProperty(true)
-Property browser bubbles change notifications from subproperty to parent property or to the control

PersistenceMode(PersistenceMode.InnerProperty)
-Whethet property is persisted on control's tag or as nested property



Thanks,

Teemu Keiski
Finland, EU
new2ASPnet
Asp.Net User
Re: Styles in composite controls11/16/2003 4:35:07 PM

0/0

Hi....

Can somebody point me to a working sample of a custom control that support design-time? like setting style in the property window of VS.NET IDE.

Thanks in advance.
The most wasted day is that in which we have not laughed.

V i r g i l R e b o t o n
5 Items, 1 Pages 1 |< << Go >> >|


Free Download:

Books:
Developing Microsoft ASP.NET Server Controls and Components Authors: Nikhil Kothari, Vandana Datye, Pages: 689, Published: 2002
Professional ASP.NET 2.0 Server Control and Component Development Authors: Shahram Khosravi, Pages: 1186, Published: 2006
Pro ASP. Net 3. 5 Server Controls and AJAX Components Authors: Rob Cameron, Dale Michalk, Pages: 740, Published: 2008
Pro ASP.NET 2.0 in VB 2005: From Professional to Expert Authors: Laurence Moroney, Matthew MacDonald, Pages: 1253, Published: 2006
Pro ASP.NET 2.0 in C# 2005 Authors: Matthew MacDonald, Mario Szpuszta, Pages: 1255, Published: 2005
Pro ASP.NET 2.0 in C# 2005: Create Next-generation Web Applications with the Latest Version of Microsoft's Revolutionary Technology Authors: Matthew MacDonald, Mario Szpuszta, Pages: 1426, Published: 2006
Pro Visual Studio 2005 Team System Application Development: Application Design Authors: Steve Shrimpton, Pages: 768, Published: 2006
Pro ASP.NET 3.5 in C# 2008 Authors: Matthew MacDonald, Mario Szpuszta, Pages: 1498, Published: 2007

Web:
Creating ASP.NET Custom Controls with Style When you build composite controls, the Render method takes on a different form. ... or by setting properties on the controls, or by applying a style. ...
Styles in composite controls - ASP.NET Forums I've been having an issue trying to get design time support for some styles i created for a composite control. I have a control that ...
Creating Composite Server Controls in ASP.NET 2.0 Jan 25, 2006 ... Simply exposing the Style property of the controls within the composite control didn't work as expected, and though you would see the Style ...
ActiveWidgets • Composite controls - adding more elements to the grid Mar 4, 2006 ... Composite controls - adding more elements to the grid ... html control grid · javascript grid controls style · adding datagrid controls ...
WPF: Customizing Controls For Windows Presentation Foundation Composite controls; Styles and templates; Custom properties; Custom controls. This article uses the following technologies: Windows Presentation Foundation ...
CodeProject: Eventing Within Composite Web Custom Controls. Free ... As there are many examples of simple composite controls, I want to focus on the ... Rendering style, while giving greater flexibility over the control ...
Apply CSS Style from External file on Composite Controls - ASP.NET ... i am creating a Menu composite control , i want to add the CSS Style from (style .css) external file in this menu control content. ...
Web Content Management ASP ASP.NET Reference Topics Sep 30, 2005 ... APIs Related to Composite Controls View State and Child Controls Event Bubbling Styles in Composite Controls - The StyledCompositeLogin ...
CoDe Magazine - Article: Creating ASP.NET Custom Controls with Style Listing 6: A composite control with style. public class CaptionedTextBox : WebControl { private string caption; private TextBox _textbox; private Style ...
Safari Books Online - 0735622019 - Microsoft® ASP.NET 2.0 Step By Step However, each style of composite controls has distinct advantages and disadvantages. The biggest advantage of custom composite controls is that they are ...

Videos:
Composite-ARF.com Extra 330L 2.6M Comp-ARF 35% scale Extra 330L with DA-100 engine and JR 8411 servos. This video was taken a few months after I started flying the plane. I've had i...
NEW BRACES The Damon 3 bracket is setting the standard for self ligation efficiency and quality. Imagine trying to drive down the road with your brakes on. Th...
New Balance ROLLBAR TPU medial and or lateral post with composite plate designed to minimize rearfoot movement (pronation and supination). When combined with TS2® provid...
Review of Insignia 22" Widescreen LCD HDTV This LCD high-definition screen is a very good buy for the low price (on sale at BestBuy for 299.99, I actually got it for 250 with some coupons I ha...
de Havilland DH98 Mosquito More Mosquito footage, some good quality stuff. The de Havilland Mosquito was a British combat aircraft that excelled in a number of roles during t...
Vintage Sci-fi Trading Cards, 1938, Space Ships, Robots, TV Please visit my card museum by clicking the blue creamofcardstv link above and the link on the left-hand-side of my profile page. This video clip fe...
RULO Y GONZALEZ RULO Y GONZALEZ FOR MORE: http://www.soyelcreador.com.ar http://www.historietayanimacion.com Traditional animation, also referred to as classical...
django: Web Development for Perfectionists with Deadlines Google TechTalks April 26, 2006 Jacob Kaplan-Moss ABSTRACT Django is one of the premier web frameworks for Python, and is often compared to Ruby-on...




Search This Site:










details about spla license

looking for a hosting solution for asp.net 2.0

advanced web user controls resources

can't set calendar properties

listcontrol having problems with children

loadcontrol(usercontrols/info.ascx) error, but i don't know the reason! please help chinese friend!

stringcollection as property

defaultvalue attribute

create custom control?

"absolute" positioning of controls in itemtemplate / header template of datalist

custom control with parent and childs objects

can't access webcontrol.page from subclass

saving viewstate of a modified control

single style declaration for multiple control instances

custom radiobuttonlist

js error in tree view web control.

odd hosting need (looking for ideas)

have probs in web user control and custom control

your opinion on some hosts in my list please

property greyed out

design time sizing - height & width

add an icon (toolbar) to user controls

adding extra functionality to validators

using controlpersister.persistcontrol at run time

net hosting need for a newbie

custom controls, viewstate and events

properties are not refreshed from onload event on the page.

about html body tag problem..when building controls

how do i expose properties in a composite control

web hosting

  Privacy | Contact Us
All Times Are GMT