HighTechTalks DotNet Forums  

Re: Question on limiting choices in WebPart personalization

ASP.net Building Controls microsoft.public.dotnet.framework.aspnet.buildingcontrols


Discuss Re: Question on limiting choices in WebPart personalization in the ASP.net Building Controls forum.



Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old   
Riki
 
Posts: n/a

Default Re: Question on limiting choices in WebPart personalization - 01-09-2007 , 11:37 AM






Just use an enum for the property.

--

Riki

"Ron Ruble" <RonRuble (AT) discussions (DOT) microsoft.com> wrote

Quote:
I've created a WebPart, as a page using the designer, I'm looking at
making
it personalizable, and ran across these attributes:

[Personalizable(), WebBrowsable, WebDisplayName("My Display Name")]

all of which works great, making the properties available through a
standard
PropertyGridEditorPart. The WebBrowsable attribute makes it visible just
fine; But I notice it uses the data type of the property to determine what
type of control to display: bool gets a checkbox, string gets a free-form
text box.

Is there a way to display a list of available string choices in a list,
without creating a personlization control? Something like a
comma-separated
list of values in an attribute I don't know about? Just looking for the
easy
way to do this. I can always read up on creating my own control if needed;
I've seen the examples.

Thanks for any ideas.



Reply With Quote
Reply




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.