Ask a Question related to Macromedia Flex General Discussion, Design and Development.
-
eztaburnak #1
Static variable/method
Hi!!
need help here..how can i access static variable and methods in a class?
tnx.
eztaburnak Guest
-
#39852 [NEW]: static variable shows abnormal performence
From: eingmarra at hotmail dot com Operating system: windowsxp sp2 PHP version: 5.2.0 PHP Bug Type: Class/Object related Bug... -
#39664 [NEW]: Invokation of non-static method as static issue
From: john dot hargrove at sellingsource dot com Operating system: Gentoo Linux 2.6 kernel PHP version: 5.2.0 PHP Bug Type: ... -
#39057 [NEW]: Documented static method isn't
From: nickj-phpbugs at nickj dot org Operating system: Ubuntu Linux PHP version: 5CVS-2006-10-06 (snap) PHP Bug Type: DOM XML... -
#38992 [NEW]: ReflectionMethod::invoke() and ::invokeArgs() static method calls should match
From: matthew at zend dot com Operating system: Debian SID on i686 PHP version: 5.1.6 PHP Bug Type: Feature/Change Request... -
static method and $this
hello php-general, i found this thread in the mailing-list archive: http://marc.theaimsgroup.com/?l=php-general&m=104182777004472&w=2 to... -
dietmar.paulus #2
Re: Static variable/method
Hey, please can you specify your problem in detail.
But normally you have access to public static variables and public static
methods outside your class with the following structur.
<YourClassName>.<YourVariableName>
e.g.
Math.PI //Where Math is your Class and PI is your public static variable
and the same for methods
dietmar.paulus Guest
-
eztaburnak #3
Re: Static variable/method
tnx for the reply..I want to access the treeData under the
hierarchicalCollectionView property of advanceDatagrid.
what i did is
private var myGrid:AdvancedDataGrid = new AdvancedDataGrid();
myGrid.hierarchicalCollectionView.treeData;
and i got this error
1119: Access of possibly undefined property treeData through a reference with
static type mx.collections:IHierarchicalCollectionView. advancedgrid/src
well!! im sure treeData is existing i run debug and its there. So it came up
that it might be a static variable of method. I tried to do some experiments
and i found out static methods and variables are not accessible outside the
class.
tnx.
eztaburnak Guest
-
dietmar.paulus #4
Re: Static variable/method
Yeah, but if you look in the debugger you will see that the icon before the treeData is yellow, this means that this property is protected and not public
dietmar.paulus Guest
-
dietmar.paulus #5
Re: Static variable/method
A question,
why don't you use
myGrid.hierarchicalCollectionView.source??
dietmar.paulus Guest
-
eztaburnak #6
Re: Static variable/method
yes...exactly!!! is there any ways i could access the protected property? tnx i will that one.. : )
eztaburnak Guest
-
dietmar.paulus #7
Re: Static variable/method
About protected variables and methods have a look at the Dokumentation, in the
section LanguageElements and then search for protected.
For short: You only have access to protected properties and methods only in
subclasses.
dietmar.paulus Guest
-
eztaburnak #8
Re: Static variable/method
tnx.you're a big help.... :) i am new in flex.
eztaburnak Guest
-



Reply With Quote

