PhAB newbie question (very newbie)

Hi!

I just got started with QNX, Neutrino & Photon and I’m trying to
manipulate a simple progress bar using PhAB. I’ve named my PtProgress
resource myProgress, I modified my abmain.c file to do a
SetResource(ABW_myProgress, Pt_ARG_GAUGE_VALUE, 20,0);
Just to see if I can manipulate the value. But when I do a Make I get an
error ‘…ABW_myProgress’ undeclared…’

I can see ABW_myProgress in the abdefine.h & the ABN_myProgress in the
abvars.h so I know I’m declaring it somewhere. Do I need to define my
widget further in abmain.c? Or what am I doing wrong? Something really
silly I’m sure.

As an aside. I noticed its really easy to hit Generate and wipe out my
abmain.c file changes. What techniques do others use to avoid losing
code? Backup often. Disable the Generate button somehow?

Hope this is the right newsgroup for this type of question. If not could
you redirect me?

thx

Eric


I’d change the world if I could remember my password

ok, 2 seconds after I wrote this, I went and copied the ABW manifest name
from abdefine.h and the thing compiled. Must’ve had a name slightly wrong.
Weird…But it didn’t change the look of my progress bar when I ran it. I
guess I expected the bar to show a value of 20 (not my initial val of 0). Do
I need to do something else to propagate the change to the widget?

Eric Winger wrote:

Hi!

I just got started with QNX, Neutrino & Photon and I’m trying to
manipulate a simple progress bar using PhAB. I’ve named my PtProgress
resource myProgress, I modified my abmain.c file to do a
SetResource(ABW_myProgress, Pt_ARG_GAUGE_VALUE, 20,0);
Just to see if I can manipulate the value. But when I do a Make I get an
error ‘…ABW_myProgress’ undeclared…’

I can see ABW_myProgress in the abdefine.h & the ABN_myProgress in the
abvars.h so I know I’m declaring it somewhere. Do I need to define my
widget further in abmain.c? Or what am I doing wrong? Something really
silly I’m sure.

As an aside. I noticed its really easy to hit Generate and wipe out my
abmain.c file changes. What techniques do others use to avoid losing
code? Backup often. Disable the Generate button somehow?

Hope this is the right newsgroup for this type of question. If not could
you redirect me?

thx

Eric


I’d change the world if I could remember my password


I’d change the world if I could remember my password

It sounds like you are doing things right by using PtSetResource().
I am just wondering how you are invoking it? I created a test application to
test what you are trying to do and I added a button along with the progress bar
and set the resource in the Activate callback of the button. That way when I
click on the button the progress bar indicator moves to a value of 20.

For PhAB questions, the best newsgroups would be
qdn.public.qnxrtp.photon or
qdn.public.qnxrtp.applications


Regards,

Barry





Eric Winger <ewinger@keyww.com> wrote:

ok, 2 seconds after I wrote this, I went and copied the ABW manifest name
from abdefine.h and the thing compiled. Must’ve had a name slightly wrong.
Weird…But it didn’t change the look of my progress bar when I ran it. I
guess I expected the bar to show a value of 20 (not my initial val of 0). Do
I need to do something else to propagate the change to the widget?

Eric Winger wrote:

Hi!

I just got started with QNX, Neutrino & Photon and I’m trying to
manipulate a simple progress bar using PhAB. I’ve named my PtProgress
resource myProgress, I modified my abmain.c file to do a
SetResource(ABW_myProgress, Pt_ARG_GAUGE_VALUE, 20,0);
Just to see if I can manipulate the value. But when I do a Make I get an
error ‘…ABW_myProgress’ undeclared…’

I can see ABW_myProgress in the abdefine.h & the ABN_myProgress in the
abvars.h so I know I’m declaring it somewhere. Do I need to define my
widget further in abmain.c? Or what am I doing wrong? Something really
silly I’m sure.

As an aside. I noticed its really easy to hit Generate and wipe out my
abmain.c file changes. What techniques do others use to avoid losing
code? Backup often. Disable the Generate button somehow?

Hope this is the right newsgroup for this type of question. If not could
you redirect me?

thx

Eric


I’d change the world if I could remember my password


I’d change the world if I could remember my password

Previously, Eric Winger wrote in comp.os.qnx:

As an aside. I noticed its really easy to hit Generate and wipe out my
abmain.c file changes. What techniques do others use to avoid losing
code? Backup often. Disable the Generate button somehow?

The rule I’ve been told is that you should never modify anything
in your working directory that starts with an ‘a’. That is unless
it is your own file.

Mitchell Schoenbrun --------- maschoen@pobox.com