home *** CD-ROM | disk | FTP | other *** search
- Subject: Re: Scripting Problem
- Sent: 8/1/96 8:09 PM
- Received: 8/2/96 8:39 AM
- From: Serge Froment, sfroment@odyssee.net
- Reply-To: ODF Interest, ODF-Interest@CILabs.ORG
- To: OpenDoc Development Framework Discussion List, ODF-Interest@CILabs.
-
- >When I write a script like "get myProperty of first myClass", I actually
- >get the property. But when I write a script like "get first myClass", I get
- >an error message saying "Can't make myClass 1 into myClass 1". Similar
- >script with ODFDraw returns a result like "shape 1 of application ODFDraw
- >Sample".
-
- I have found the problem: FW_MScriptable::GetProperty does handle both
- pClass and pIndex, but FW_MScriptable::HasProperty returns true only for
- pClass. I don't know if this is a bug of ODF or a feature. I have added
- pIndex to CMyScriptable::HasProperty, like ODFDraw does. Actually, I had to
- handle pIndex in CMyScriptable::GetProperty also because the method used by
- FW_MScriptable does not work when FW_MScriptable objects are generated on
- the fly like I do.
-
- Serge
-
-
-