comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: ENUMLIST in IDLitComponent::RegisterProperty
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: ENUMLIST in IDLitComponent::RegisterProperty [message #39423 is a reply to message #39415] Wed, 19 May 2004 12:44 Go to previous message
Chris[2] is currently offline  Chris[2]
Messages: 39
Registered: August 2003
Member
Hi Sean,

The way to do this is to just change the value of the property itself. For
example, in your case, I assume you have some member data in your object,
say "self.people" (which I assume is an integer).

So in your ::Init method, you could just set "self.people=2", and the
initial setting of the property will then be 2, which will correspond to
"Harry".

You can do this for any property, not just registered properties, and not
just enumlists.

Now, as an aside, you can also mark a property as "Undefined", using the
UNDEFINED keyword to ::RegisterProperty. It won't change the actual property
value, but in the property sheet it will appear as if nothing was selected.
If you do this, you will need to programmatically set it back to "defined".
The property sheet won't do it for you. See IDLitComponent::RegisterProperty
for details.

-Chris
Research Systems, Inc.


"Sean Dettrick" <sdettrick@hotmail.com> wrote in message
news:c233c3ea.0405181254.319e4ab9@posting.google.com...
> Hi,
> I have a quick question.
>
> Has anybody come up with a way to give an ENUMLIST property an initial
> value which is NOT zero? E.g. if:
>
> LIST=['Tom','Dick','Harry']
> self -> IDLitComponent::RegisterProperty, 'PEOPLE', $
> ENUMLIST=LIST, $
> NAME='Friends'
>
> The default setting will be 'Tom'. Is it possible to change the
> DEFAULT setting, without changing the order of LIST?
>
> Thanks,
> Sean
[Message index]
 
Read Message
Read Message
Previous Topic: main parameters
Next Topic: where to download older versions

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Thu Mar 26 01:50:16 PDT 2026

Total time taken to generate the page: 1.52271 seconds