REFRESH PICTURE in DW PICTURE BOX

 

  1. Insert picture control in dw form i.e PictureBox1
  2. Create constant i.e RefreshPictureBoxTF and set value to "true"
  3. Add TextBox that will hold value that changes i.e.  Textbox1
  4. Add listbox, set its "Items" property to Textbox1Return object that is changing value
  5. Create Specification Macro(i.e AlternatePictureBoxPicture),
  6. Add "Drive Constant value" from the toolbox
  7. In the "Constant Value" add: Not(DwConstantRefreshPictureBoxTF)
  8. Constant Name: DwConstantRefreshPictureBoxTF
  9. Connect it to "Start"
  10. Go back to the listbox  (named under #4) and add in "OnChange" event name of the specification Macro (named under #5)
  11. Create Variable to call mijoPPGauge( using mijoPowerPack Framework for DriveWorks
  12. In the picturebox1,  in the FileName property add the following:


If(DwConstantRefreshPictureBoxTF=TRUE, Substitute(DWVariablemijoGaugeTemp01ImagePath,"01","01_1"),Substitute(DWVariablemijoGaugeTemp01ImagePath,"01","01_2"))