Here is an example of how to use the kdialog progressbar. It works.
dbusRef=`kdialog --progressbar "Press Cancel at Any time" 10` qdbus $dbusRef showCancelButton true until test "true" = `qdbus $dbusRef wasCancelled`; do sleep 1 inc=$((`qdbus $dbusRef Get "" "value"` + 1)) qdbus $dbusRef Set "" "value" $inc; done qdbus $dbusRef close
However, I can't figure out how to make it work when the main script file calls a 2nd script file. I want to keep updating the same progress bar from the second script.
The error is:
- qdbus Set '' value 53 Path '' is not a valid path name.
The code to update the progressbar is exactly the same in the second script file as the first. Generically, it is this:
qdbus $dbusRef Set "" value "$PROGRESS"
Obviously, some variable values are not getting passed around. But none of the tutorials I have seen explain the variables. For example, what is
value? What is
In short, how do I update the same progressbar from a second bash script file that is called by the first?