fn ApName()

I want to go through all widgets in current container ( PtPane in my case ).
But I encounter problem with ApName() function.

code snipset:

for( cw = link_instance; ( cw = PtWidgetFamily( link_instance, cw ) ) !=
NULL; )
index = ApName( cw );

For all “named” widgets ( ABW instances generated in PhAB ) I’ve got correct
ApName value ( same as ABN_ ). For unnamed widgets fn ApName() returns -1.
So far good. When PtNumericInterger is placed in PtPane, I’ve got 6 widgets
where ApName() returns values like 1940040(2x), 1941216(4x). This 6 widgets
are subordinate children of PtNumericInteger and are ordered right after
PtNumericInteger. Return value of ApName() for this widgets is apparently
wrong.

Is there any flag indicating that ApName() value for current widget is
incorrect? Any solution?

PS: I try fn ApInstanceName() for current widget in my code snipset (cw).
Again fn ApInstanceName() return NULL or corrent name ( when I include name
in PhAB ), with subordinate children of PtNumericInteger I’ve got poiter to
nowhere ( neither NULL nor string ).

Martin Michalek <michalek@procaut.sk> wrote:

I want to go through all widgets in current container ( PtPane in my case ).
But I encounter problem with ApName() function.

code snipset:

for( cw = link_instance; ( cw = PtWidgetFamily( link_instance, cw ) ) !=
NULL; )
index = ApName( cw );

For all “named” widgets ( ABW instances generated in PhAB ) I’ve got correct
ApName value ( same as ABN_ ). For unnamed widgets fn ApName() returns -1.
So far good. When PtNumericInterger is placed in PtPane, I’ve got 6 widgets
where ApName() returns values like 1940040(2x), 1941216(4x). This 6 widgets
are subordinate children of PtNumericInteger and are ordered right after
PtNumericInteger. Return value of ApName() for this widgets is apparently
wrong.

Is there any flag indicating that ApName() value for current widget is
incorrect? Any solution?

PS: I try fn ApInstanceName() for current widget in my code snipset (cw).
Again fn ApInstanceName() return NULL or corrent name ( when I include name
in PhAB ), with subordinate children of PtNumericInteger I’ve got poiter to
nowhere ( neither NULL nor string ).

You need to ignore any widgets that have the Pt_PROCREATED flag set in
Pt_ARG_FLAGS.