Page 1 of 1

Statusbar Statusitem updating ...

Posted: Wed Jan 26, 2011 1:50 am
by DenCo
I'm new, and I've been away for awhile, but it's all been spent working and learning with HMG , 3 series ....

I'm having good luck with it... Today's question is a simple topic...

I have a main window ,, wind_1 The statusbar / statusitem looks like this

STATUSITEM "Schedule Tracking : Current Line Selected : " +mPath

mPath is a PUBLIC variable that holds the path and name of the area we are working with.....

When the program starts ,, mPath is set to the last place we were working with when we quit the last time ...

The window signs on looking like ;; Current Line Selected : c:\sch39m\Line594

It all works well .... I have a routine that allows us to change locations. That works good,,,, mPath value changes to the correct new path information....

All other processes work and open the correct files in the correct location we have changed to (mPath) .... The mechanicals work...

My problem,,, I can't get the statusitem on my main window to update and show the changed value of (mPath) in the statusitem...

I'm sorry for a long post over a cosmetic item ... It's the little stuff I have problems with.

Bill

Re: Statusbar Statusitem updating ...

Posted: Wed Jan 26, 2011 5:06 am
by Rathinagiri
DenCo wrote:I'm new, and I've been away for awhile, but it's all been spent working and learning with HMG , 3 series ....

I'm having good luck with it... Today's question is a simple topic...

I have a main window ,, wind_1 The statusbar / statusitem looks like this

STATUSITEM "Schedule Tracking : Current Line Selected : " +mPath

mPath is a PUBLIC variable that holds the path and name of the area we are working with.....

When the program starts ,, mPath is set to the last place we were working with when we quit the last time ...

The window signs on looking like ;; Current Line Selected : c:\sch39m\Line594

It all works well .... I have a routine that allows us to change locations. That works good,,,, mPath value changes to the correct new path information....

All other processes work and open the correct files in the correct location we have changed to (mPath) .... The mechanicals work...

My problem,,, I can't get the statusitem on my main window to update and show the changed value of (mPath) in the statusitem...

I'm sorry for a long post over a cosmetic item ... It's the little stuff I have problems with.

Bill
The point is, it is not automatically done. We have to run this statement whenever the value of mPath changes.

Re: Statusbar Statusitem updating ...

Posted: Wed Jan 26, 2011 10:13 am
by gfilatov
Hello,

Try the following line after updating of mPath variable:

Code: Select all

...
wind_1.StatusBar.Item(1) := "Schedule Tracking : Current Line Selected : " +mPath
Hope that helps :idea:

Re: Statusbar Statusitem updating ...

Posted: Thu Jan 27, 2011 5:00 am
by DenCo
Thank You both for your replies..

I knew I would have to restate the value for it to update,,, just every syntax I could think of either threw an error,, or did nothing ...

Gfilatov,, your example worked perfectly ! .... Thanks again ...

Bill